Class: EY::Serverside::DependencyManager::Npm

Inherits:
Base
  • Object
show all
Defined in:
lib/engineyard-serverside/dependency_manager/npm.rb

Instance Attribute Summary

Attributes inherited from Base

#config, #runner, #servers, #shell

Instance Method Summary collapse

Methods inherited from Base

#check, detect, #initialize, #rails_version, #show_ey_config_instructions, #uses_sqlite3?

Constructor Details

This class inherits a constructor from EY::Serverside::DependencyManager::Base

Instance Method Details

#detected?Boolean

Returns:

  • (Boolean)

7
8
9
# File 'lib/engineyard-serverside/dependency_manager/npm.rb', line 7

def detected?
  paths.package_json.exist?
end

#installObject


11
12
13
14
# File 'lib/engineyard-serverside/dependency_manager/npm.rb', line 11

def install
  shell.status "Installing npm packages (package.json detected)"
  run "cd #{paths.active_release} && npm install"
end