Class: Chid::Commands::Installs::Rvm
- Inherits:
-
Chid::Command
- Object
- Chid::Command
- Chid::Commands::Installs::Rvm
- Defined in:
- lib/chid/commands/installs/rvm.rb
Constant Summary
Constants inherited from Chid::Command
Instance Attribute Summary
Attributes inherited from Chid::Command
Instance Method Summary collapse
Methods inherited from Chid::Command
command, help, #initialize, map_options_with_values, run
Constructor Details
This class inherits a constructor from Chid::Command
Instance Method Details
#run ⇒ Object
23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
# File 'lib/chid/commands/installs/rvm.rb', line 23 def run puts "\nInstalling the RVM..." system('gpg --keyserver hkp://pool.sks-keyservers.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3 7D2BAF1CF37B13E2069D6956105BD0E739499BDB') ::ChidConfig.on_linux do system('sudo apt-get install software-properties-common') system('sudo apt-get install curl') system('sudo apt-add-repository -y ppa:rael-gc/rvm') system('sudo apt-get update') system('sudo apt-get install rvm') system("echo 'source \"/etc/profile.d/rvm.sh\"' >> ~/.bashrc") end ::ChidConfig.on_osx do system('\curl -sSL https://get.rvm.io | bash -s stable --ruby') end puts "\nRVM installed successfully" puts "\nPlease rebot your terminal" end |