git-deploy 0.5.0 → 0.5.1

Sign up to get free protection for your applications and to get access to all the features.
data/lib/git_deploy.rb CHANGED
@@ -25,7 +25,7 @@ class GitDeploy < Thor
25
25
  def setup
26
26
  sudo = options.sudo? ? "#{sudo_cmd} " : ''
27
27
 
28
- if run_test("test -x #{deploy_to}")
28
+ unless run_test("test -x #{deploy_to}")
29
29
  run ["#{sudo}mkdir -p #{deploy_to}"] do |cmd|
30
30
  cmd << "#{sudo}chown $USER #{deploy_to}" if options.sudo?
31
31
  end
@@ -9,8 +9,14 @@ RAILS_ENV = ENV['RAILS_ENV'] || 'production'
9
9
  use_bundler = File.file? 'Gemfile'
10
10
  rake_cmd = use_bundler ? 'bundle exec rake' : 'rake'
11
11
 
12
- # update gem bundle
13
- run "bundle install --deployment" if use_bundler
12
+ if use_bundler
13
+ bundler_args = ['--deployment']
14
+ BUNDLE_WITHOUT = ENV['BUNDLE_WITHOUT'] || 'development:test'
15
+ bundler_args << '--without' << BUNDLE_WITHOUT unless BUNDLE_WITHOUT.empty?
16
+
17
+ # update gem bundle
18
+ run "bundle install #{bundler_args.join(' ')}"
19
+ end
14
20
 
15
21
  if File.file? 'Rakefile'
16
22
  num_migrations = `git diff #{oldrev} #{newrev} --diff-filter=A --name-only`.split("\n").size
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: git-deploy
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.5.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2011-10-04 00:00:00.000000000 Z
12
+ date: 2011-10-11 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: thor
16
- requirement: &70292395458180 !ruby/object:Gem::Requirement
16
+ requirement: &70176242907060 !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,10 +21,10 @@ dependencies:
21
21
  version: '0'
22
22
  type: :runtime
23
23
  prerelease: false
24
- version_requirements: *70292395458180
24
+ version_requirements: *70176242907060
25
25
  - !ruby/object:Gem::Dependency
26
26
  name: net-ssh
27
- requirement: &70292395455260 !ruby/object:Gem::Requirement
27
+ requirement: &70176242905040 !ruby/object:Gem::Requirement
28
28
  none: false
29
29
  requirements:
30
30
  - - ! '>='
@@ -32,10 +32,10 @@ dependencies:
32
32
  version: '0'
33
33
  type: :runtime
34
34
  prerelease: false
35
- version_requirements: *70292395455260
35
+ version_requirements: *70176242905040
36
36
  - !ruby/object:Gem::Dependency
37
37
  name: net-scp
38
- requirement: &70292395453880 !ruby/object:Gem::Requirement
38
+ requirement: &70176242903080 !ruby/object:Gem::Requirement
39
39
  none: false
40
40
  requirements:
41
41
  - - ! '>='
@@ -43,7 +43,7 @@ dependencies:
43
43
  version: '0'
44
44
  type: :runtime
45
45
  prerelease: false
46
- version_requirements: *70292395453880
46
+ version_requirements: *70176242903080
47
47
  description: A tool to install useful git hooks on your remote repository to enable
48
48
  push-based, Heroku-like deployment on your host.
49
49
  email: mislav.marohnic@gmail.com