richo / _vm

Generic version manager
MIT License
12 stars 1 forks source link

Support for linked tools #5

Open richo opened 10 years ago

richo commented 10 years ago

It'd be awesome for some linked tools to do sane things; ie it makes sense to be able to manipulate GEM_HOME independantly of your ruby verison, in order to use system ruby but local gems.

This is awkward though, as a user does it make more sense to:

,ruby gems <path>

And make peace with the fact that if you install a ruby called gems you're forever doomed to weirdness, OR

,gem <path|name>

and make peace with ,gem and ,ruby being inexorably linked and potentially writing hairier/wierder code to deal with it.

/cc @lox and @alec666 as the only people I know using this day to day.

lox commented 10 years ago

,ruby-config gems <path> ? So it's clear it's related?

richo commented 10 years ago

Hrm, yeah that seems plausible. This might finally be the kick I need to actually build a compiler for it.

richo commented 10 years ago

Having thought about this, I think I'm going to roll forward with

,ruby::gems <path>

and potentially rip out the references to system across tools, replacing it with --reset to make it more obvious what you're going to do, since

,ruby 1.9.3-194 # selects 1.9.3-194
,ruby::gems butts # Store gems in butts for now
,ruby::gems --reset # revert to using default gem storage for 1.9.3-194
,ruby --reset # revert gem storage and ruby to defaults