Class: Escualo::Plugin::Node
- Inherits:
-
Object
- Object
- Escualo::Plugin::Node
- Defined in:
- lib/escualo/plugin/node.rb
Instance Method Summary collapse
Instance Method Details
#installed?(session, _options) ⇒ Boolean
11 12 13 |
# File 'lib/escualo/plugin/node.rb', line 11 def installed?(session, ) session.tell!('nvm use node').include? 'Now using node v4.2.4' rescue false end |
#run(session, _options) ⇒ Object
3 4 5 6 7 8 9 |
# File 'lib/escualo/plugin/node.rb', line 3 def run(session, ) session.tell_all! 'curl -o- https://raw.githubusercontent.com/creationix/nvm/v0.30.2/install.sh | bash', '. ~/.bashrc', 'nvm install 4.2.4', 'nvm alias default node' end |