From: Jon Cairns Date: 2013-02-06T18:48:36+09:00 Subject: Expanding gemspecs Hi everyone, I've got a question about the existence or potential usefulness of a particular gem. The situation is this: all gems have a gemspec file that defines various properties about the gem. When creating a new gem with bundler, it puts in some shortcuts to generating that information, such as using git to list files in the gem, requiring a file and class constant to retrieve the version number and using grep to discover test files. This is great during development, but has a slight performance effect for the end user when loading the gem. Multiply that by 20, 30, 40+ and you start to get a noticeable delay when loading all gems (particularly noticeable when starting rails). So far I haven't said anything new: this has been brought up before and, as far as I know, there isn't a universal solution yet. Some people create Rake tasks to build their gemspecs, but what about a gem? E.g. a command line tool to produce a fully qualified gemspec from a template. I think that Jeweller used to do it, but that's no longer maintained as people tend towards using bundler now. Is there a gem in existence that parses the gemspec, producing an expanded version that can then be used when packaging and delivering the gem? A quick Google search returned nothing, so I wrote a small script to do it. I was toying with the idea of turning it into a gem, but wanted to pass it under the noses of seasoned rubyists to see what the general feeling was. Any thoughts? Cheers, Jon :) -- Posted via http://www.ruby-forum.com/.