Prev: XMPP client with Ruby
Next: ruby bounties update
From: R.. Kumar on 24 Jun 2010 00:56 Thomas Sawyer wrote: > On Jun 23, 10:12�am, Roger Pack <rogerpack2...(a)gmail.com> wrote: >> > bundling your library as a gem. This was a problem for Rack for a while >> > as some tools will move the lib dir out and break your relative path. >> >> Good point. For bundling sake I'd therefore suggest moving the file >> VERSION into your lib dir. �Though, in reality, it's probably the tools >> that should bundle the whole gem not just its lib dir...at least if they >> want to be totally gem compatible. > > Easy solution: > > cd lib/foo > ln -s ../../VERSION version.yml > > Or .txt as the case may be. Actually, I thought of this earlier. The mistake I made was of trying to read the file using require or load and of course got the error. Then, i wondered whether the link would be portable -- if someone forks, or updates the gem it won't work. But i suppose that's not too important ? -- Posted via http://www.ruby-forum.com/. |