rvm1-capistrano3 0.8.0 → 0.9.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 2da7ddee8d21fd4ef862fa1031a2dad65648b23a
4
- data.tar.gz: df1d69d6dac6d4dd1842abead1ef8fffd7f557f8
5
2
  SHA512:
6
- metadata.gz: c6089aedcffa9d69b1b03373652d4c5333fcbf31a5e3499c369d40fa2ce3e7813129e0caa5c86f5d4e558afadf3a2cc9cdeedbc07cc0f807ddf152a2354d9831
7
- data.tar.gz: 5c56b8e712baab3470c2a3e1d1897c0b7b131e3df6bcb70c06037d2629128a1f7bf23eef7218a59f22ada2cc79dd91bb169a1fb33009d7dd43789c6b0b84e8e9
3
+ data.tar.gz: 84bb26b89bfda0fa7c8c7a56ece14664aeb616defdbb586d3718166224fea7755bcd58caec9c8213b8fb08795a51c421a5f455c59e657758b5885df10afe9a86
4
+ metadata.gz: a8c5c51d287577eed8aa3210026ee4d4531862421c2ae8459ca1f506f3101dbac853533bd3953e52d64c29f20f37d834731bf6b287625592bd9b15a513a727da
5
+ SHA1:
6
+ data.tar.gz: 541da513f4c5e7aa0fcc817fc5f4aff6d5d73997
7
+ metadata.gz: 92d407c0e5906c1aef66011e2764a01eda35c022
@@ -1 +1,2 @@
1
1
  load File.expand_path("../tasks/capistrano3.rake", __FILE__)
2
+ load File.expand_path("../tasks/capistrano3/install.rake", __FILE__)
@@ -1,5 +1,5 @@
1
1
  module RVM1
2
2
  class Capistrano3
3
- VERSION="0.8.0"
3
+ VERSION="0.9.0"
4
4
  end
5
5
  end
@@ -27,11 +27,12 @@ namespace :rvm1 do
27
27
  puts capture(:rvm, "version")
28
28
  puts capture(:rvm, "list")
29
29
  puts capture(:rvm, "current")
30
- within fetch(:latest_release_directory) do
30
+ within fetch(:release_path) do
31
31
  puts capture(:ruby, "--version || true")
32
32
  end
33
33
  end
34
34
  end
35
+ before :check, "deploy:updating"
35
36
  before :check, 'rvm1:hook'
36
37
 
37
38
  task :init do
@@ -0,0 +1,24 @@
1
+ namespace :rvm1 do
2
+ namespace :install do
3
+ desc "Installs RVM 1.x user mode"
4
+ task :rvm do
5
+ on roles(:all) do
6
+ execute :mkdir, "-p", "#{fetch(:tmp_dir)}/#{fetch(:application)}/"
7
+ upload! File.expand_path("../../../../../script/install-rvm.sh", __FILE__), "#{fetch(:tmp_dir)}/#{fetch(:application)}/install-rvm.sh"
8
+ execute :chmod, "+x", "#{fetch(:tmp_dir)}/#{fetch(:application)}/install-rvm.sh"
9
+ execute "#{fetch(:tmp_dir)}/#{fetch(:application)}/install-rvm.sh"
10
+ end
11
+ end
12
+
13
+ desc "Installs Ruby for the given ruby project"
14
+ task :ruby do
15
+ on roles(:all) do
16
+ within fetch(:release_path) do
17
+ execute "#{fetch(:tmp_dir)}/#{fetch(:application)}/rvm-auto.sh", "rvm", "use", "--install", fetch(:rvm1_ruby_version)
18
+ end
19
+ end
20
+ end
21
+ before :ruby, "deploy:updating"
22
+ before :ruby, 'rvm1:hook'
23
+ end
24
+ end
@@ -0,0 +1,24 @@
1
+ #!/usr/bin/env sh
2
+
3
+ # silence curl via configuration
4
+ export CURL_HOME="${TMP_DIR:-/tmp}/.rvm-curl-config.$$"
5
+ mkdir "${CURL_HOME}/" &&
6
+ {
7
+ test -r "${HOME}/.curlrc" && cat "${HOME}/.curlrc"
8
+ echo "silent"
9
+ echo "show-error"
10
+ } > "$CURL_HOME/.curlrc" ||
11
+ exit $?
12
+
13
+ # run the installer
14
+ if \curl -L https://get.rvm.io -o rvm-installer.sh && bash rvm-installer.sh stable
15
+ then __LAST_STATUS=0
16
+ else __LAST_STATUS=$?
17
+ fi
18
+ rm -f rvm-installer.sh
19
+
20
+ # cleanup curl
21
+ rm -rf "$CURL_HOME"
22
+
23
+ # return installer status
24
+ exit ${__LAST_STATUS}
data/script/rvm-auto.sh CHANGED
@@ -16,9 +16,9 @@ ruby_string="$1"
16
16
  shift
17
17
 
18
18
  # if rvm_path not set autodetect it
19
- if test -n "${rvm_path:-}"
20
- then true
21
- else
19
+ if
20
+ test -z "${rvm_path:-}"
21
+ then
22
22
  export rvm_path
23
23
  if test -x "$HOME/.rvm/bin/rvm"
24
24
  then rvm_path="$HOME/.rvm"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rvm1-capistrano3
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.0
4
+ version: 0.9.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michal Papis
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2013-10-27 00:00:00 Z
12
+ date: 2013-10-28 00:00:00 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: capistrano
@@ -43,7 +43,9 @@ extra_rdoc_files: []
43
43
  files:
44
44
  - lib/rvm1/capistrano3.rb
45
45
  - lib/rvm1/capistrano3/version.rb
46
+ - lib/rvm1/tasks/capistrano3/install.rake
46
47
  - lib/rvm1/tasks/capistrano3.rake
48
+ - script/install-rvm.sh
47
49
  - script/rvm-auto.sh
48
50
  - test/script_rvm-auto_comment_test.sh
49
51
  homepage: https://github.com/rvm/rvm1-capistrano3