Method: Bcpm::Update.upgrade
- Defined in:
- lib/bcpm/update.rb
.upgrade(branch = 'master') ⇒ Object
Updates bcpm to the latest version.
10 11 12 13 14 15 16 17 18 19 |
# File 'lib/bcpm/update.rb', line 10 def self.upgrade(branch = 'master') source_path = tempdir return false unless Bcpm::Git.clone_repo(repo_uri, 'master', source_path) success = nil Dir.chdir source_path do success = Kernel.system 'rake', 'install' end FileUtils.rm_r source_path success end |