0

i'm using rvm, i installed ruby 2.0 with rvm but i need to uninstall it to get ruby 1.9.3. But my terminal is doing strange things:

MacBook-Pro-Kuba:~ Kuba$ gem install bundler
Successfully installed bundler-1.3.5
Parsing documentation for bundler-1.3.5
1 gem installed
MacBook-Pro-Kuba:~ Kuba$ sudo rvm all do uninstall ruby
Preparing Uninstall...
Uninstall Began...
Uninstall Failed...
Reason: ErrorMissingBundle

So as you can see i'm definitely having bundler installed, and it's throwing this error. What should i do? (i use mountain lion)

Leo
  • 2,061
  • 4
  • 30
  • 58
  • Please see this: http://stackoverflow.com/questions/8319495/how-to-reinstall-ruby-and-gem-on-mac-os-x – Chubby Boy Jun 23 '13 at 09:48
  • 2
    i dont see my solution there... users there tell this guy to use rvm which im already using – Leo Jun 23 '13 at 09:56
  • explaining your command problems 1. `sudo` losses whole environment you should not prefix your commands with sudo, if you have to - use `rvmsudo`, 2. `rvm ... do ...` runs any commands it does not assume the command is prefixed with `rvm`, so your command meant to run system command `uninstall` in every ruby in rvm, not to uninstall every ruby, that would be: `rvm uninstall all`. – mpapis Jun 24 '13 at 18:58

1 Answers1

6

Why do you need to uninstall ruby2.0 to get ruby1.9.3? The whole idea of rvm is that you can have (and switch between) many different versions.

List the Rubies with rvm list.

Install (if required) with rvm install 1.9.3.

Swap to it with rvm use 1.9.3.

Leigh
  • 12,038
  • 4
  • 28
  • 36