On Fri, 29 Aug 2008 11:14:45 -0500, James Gray wrote:
There's no reason to use a shell script. Ruby supports this directly:
./configure … --program-suffix=18
That would add a 18 suffix to all programs built: ruby18, irb18, etc.
Hi James-
Nice tip, but I was referring to a shell script that would jiggle some symbolic links in /usr/local/bin so that I could switch "ruby" between 1.9.0, 1.8.6 and MacRuby...
Best, Charles
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 29 Aug 2008, at 5:48 pm, Charles Turner wrote:
On Fri, 29 Aug 2008 11:14:45 -0500, James Gray wrote:
There's no reason to use a shell script. Ruby supports this directly:
./configure … --program-suffix=18
That would add a 18 suffix to all programs built: ruby18, irb18, etc.
Hi James-
Nice tip, but I was referring to a shell script that would jiggle some symbolic links in /usr/local/bin so that I could switch "ruby" between 1.9.0, 1.8.6 and MacRuby...
Ah, but once you've built a few rubies with different suffixes (ruby18, ruby19, rubymac, etc) you can then write such a script easily:
SUFFIX=$1
ln -s /usr/local/bin/ruby$SUFFIX /usr/local/bin/ruby ln -s /usr/local/bin/irb$SUFFIX /usr/local/bin/irb ...
Best, Charles
ABS
- -- Alaric Snell-Pym Work: http://www.snell-systems.co.uk/ Play: http://www.snell-pym.org.uk/alaric/ Blog: http://www.snell-pym.org.uk/?author=4
On Fri, 29 Aug 2008 21:42:36 +0100, Alaric Snell-Pym wrote:
Ah, but once you've built a few rubies with different suffixes (ruby18, ruby19, rubymac, etc) you can then write such a script easily:
SUFFIX=$1
ln -s /usr/local/bin/ruby$SUFFIX /usr/local/bin/ruby ln -s /usr/local/bin/irb$SUFFIX /usr/local/bin/irb
Hi Alaric-
That's exactly what I did, although I'm no bash wizard, and didn't think to use a command line argument.
:-)
Thanks, Charles