Ryan Pavlik wrote:
Almost there. It won't work if you've got 1.8.0 and 1.8.1 both
installed (if you installed 1.8.1 later, requiring 'rbconfig'
generates an error).
Maybe installing one over the other... that's not a good thing. I
suggest using Encap. ;-) But it works fine with 1.8.1 here.
And it doesn't detect that you started ruby with an alias ('alias
rv=ruby -v)', but it's good enough for my purposes.
That, of course, is impossible.
What I was looking for was a way to see the original command
line. On linux I could use the proc file system, but that's just
linux...
Oh, well, you should have said that right off. That's not generally
possible. Certainly, there's no (portable) way to get the invocation
from the shell or otherwise. Even if you could, aliases are expanded
before the shell executes the command, so you couldn't get that,
either.
<snip>