Browse files

cleaning, improving

  • Loading branch information...
1 parent 5389456 commit f313f00e703de142f274ac4dd76f6cfb24a942f5 @mpapis mpapis committed Mar 26, 2012
Showing with 42 additions and 19 deletions.
  1. +8 −2 History.md
  2. +1 −0 Manifest.yml
  3. +20 −4 README.md
  4. +1 −0 lib/rvm-capistrano.rb
  5. +2 −6 lib/rvm/capistrano.rb
  6. +5 −0 lib/rvm/capistrano/version.rb
  7. +5 −7 rvm-capistrano.gemspec
View
10 History.md
@@ -1,5 +1,11 @@
-=== 1.0 / 2012-03-26
+=== 1.0.1 / 2012-03-26
+
+* Updated to latest integration code for installing rvm/ruby
+* Cleaning code, improving gemification
+* Switch the default rvm installation type to user - as we discourage system installations
+* Improved README.md
+
+=== 1.0.0 / 2012-03-26
* Ported RVM /Capistrano Gem Library into it's own repository from the main RVM
repostitory. ( https://github.com/wayneeseguin/rvm-capistrano )
-
View
1 Manifest.yml
@@ -2,5 +2,6 @@
- Manifest.yml
- README.md
- Rakefile
+- lib/rvm-capistrano.rb
- lib/rvm/capistrano.rb
- lib/rvm/capistrano/version.rb
View
24 README.md
@@ -1,16 +1,32 @@
-# rvm
+# rvm-capistrano
-https://rvm.beginrescueend.com/
+https://rvm.beginrescueend.com/integration/capistrano
## Description
RVM / Capistrano Integration Gem
## Installation
-* gem install rvm-capistrano
+RVM / Capistrano integration is now available as a separate gem
+
+ $ gem install rvm-capistrano
+
+## Example
+
+The following code will:
+
+- detect `ruby@gemset` used for deployment
+- install RVM and Ruby on `cap deploy:detup`
+
+ set :rvm_ruby_string, ENV['GEM_HOME'].gsub(/.*\//,"")
+
+ before 'deploy:setup', 'rvm:install_rvm'
+ before 'deploy:setup', 'rvm:install_ruby'
+
+ require "rvm-capistrano"
+
## Development
$ rake spec
-
View
1 lib/rvm-capistrano.rb
@@ -0,0 +1 @@
+require 'rvm/capistrano'
View
8 lib/rvm/capistrano.rb
@@ -1,9 +1,5 @@
# Recipes for using RVM on a server with capistrano.
-unless Capistrano::Configuration.respond_to?(:instance)
- abort "rvm/capistrano requires Capistrano >= 2."
-end
-
Capistrano::Configuration.instance(true).load do
# Taken from the capistrano code.
@@ -25,7 +21,7 @@ def _cset(name, *args, &block)
end
# Let users set the type of their rvm install.
- _cset(:rvm_type, :system)
+ _cset(:rvm_type, :user)
# Define rvm_path
# This is used in the default_shell command to pass the required variable to rvm-shell, allowing
@@ -111,6 +107,6 @@ def _cset(name, *args, &block)
# E.g, to use ree and rails 3:
#
-# require 'rvm/capistrano'
+# require 'rvm-capistrano'
# set :rvm_ruby_string, "ree@rails3"
#
View
5 lib/rvm/capistrano/version.rb
@@ -0,0 +1,5 @@
+module RVM
+ class Capistrano
+ VERSION="1.0.1"
+ end
+end
View
12 rvm-capistrano.gemspec
@@ -1,21 +1,20 @@
lib = File.expand_path('../lib/', __FILE__)
-
$:.unshift lib unless $:.include?(lib)
require 'rvm/capistrano/version'
require 'yaml'
Gem::Specification.new do |spec|
spec.name = 'rvm-capistrano'
- spec.version = ::RVM::Capistrano::Version
+ spec.version = ::RVM::Capistrano::VERSION
spec.platform = Gem::Platform::RUBY
- spec.authors = ['Wayne E. Seguin', '"Michał Papis, ']
+ spec.authors = ['Wayne E. Seguin', 'Michał Papis']
spec.email = ['wayneeseguin@gmail.com','mpapis@gmail.com']
- spec.homepage = 'https://rvm.beginrescueend.com/'
- spec.summary = 'RVM / Capistrano Integration Gem'
+ spec.homepage = 'https://rvm.beginrescueend.com/integration/capistrano'
+ spec.summary =
spec.description = 'RVM / Capistrano Integration Gem'
- spec.add_dependency 'capistrano'
+ spec.add_dependency 'capistrano', '>=2.0.0'
spec.add_development_dependency 'rake'
spec.add_development_dependency 'minitest'
@@ -24,4 +23,3 @@ Gem::Specification.new do |spec|
spec.files = YAML.load_file('Manifest.yml')
spec.test_files = Dir.glob('spec/**/*.rb')
end
-

0 comments on commit f313f00

Please sign in to comment.