On Sat, 2008-12-06 at 18:17 +0100, Lucas Nussbaum wrote:
On 06/12/08 at 10:44 +1100, Nic Williams wrote:
Hey everyone, (please reply-all or cc: me)
As a result, it's not easy to make them work together.
I've been looking to package some Ruby libraries and so this issue is
obviously quite important to me. I ran into a Ruby developer at the
Google Summer of Code Mentor Summit a few weeks back and we had a
discussion about this.
To understand where I'm coming from, you need to know a little bit
about
the systems that I administer. I maintain shared-hosting web servers
at
an ISP. We don't do much Rails hosting right now, except that we're
starting to use it internally.
The outcome of the discussion we had is that we both feel that Debian
should install "gems" into a system-wide location--as gems. (Apple
apparently does this already.) Given that Debian has to follow the
FHS,
I would imagine this would end up being a tree of symlinks pointing at
the FHS locations. This would be in GEM_PATH (which doesn't
necessarily
need to be setup as an environment variable per se; it could be
patched
in to the rubygems code). You'd continue to have GEM_HOME point
to /var/lib/gems (or wherever it is now), which would also be in
GEM_PATH.
Thus, if a gem is installed system-wide via APT/dpkg, it will Just
Work.
However, if you install a gem using "gem install ...", that'll Just
Work. Imagine these scenarios:
1. Richard wants to provide a number of common gems on his web servers
for use by customers.
2. Bob, a customer of Richard's, needs a newer version of a gem than
is
installed system-wide. He wants to be able to drop a newer gem into
his
vendor dir and have it override the system-wide version for his
website.
3. A security bug is found in a gem that Bob is using and Richard
wants
to install an even newer, patched version system-wide and have it
override Bob's version.
4. Richard wants to provide a gem system-wide that is not packaged in
Debian. He'd like to type "gem install FOO" and have it Just Work
(until
he can package the gem for Debian himself).
I'm not sure that all of these work well right now. They would if
Debian
were installing (which, as I said, may mean symlinks) the gems *as
gems*.
Richard