obbistrano 1.1.69 → 1.1.70

Sign up to get free protection for your applications and to get access to all the features.
@@ -149,7 +149,18 @@ Capistrano::Configuration.instance(:must_exist).load do
149
149
 
150
150
  task :git_deploy, :roles =>[:web] do
151
151
  logger.level = 2
152
- logger.info "Deploying application from #{repository} on branch #{branch}"
152
+
153
+ set :local_branch, $1 if `git branch` =~ /\* (\S+)\s/m
154
+ if !local_branch.eql? branch
155
+ logger.info "You are on branch #{local_branch}, not #{branch}, please check out there before deploying to be able to combine the correct js and css files."
156
+ exit
157
+ end
158
+
159
+ if defined? "#{commit}"
160
+ logger.info "Deploying application from #{repository} on commit #{commit}"
161
+ else
162
+ logger.info "Deploying application from #{repository} on branch #{branch}"
163
+ end
153
164
  logger.level = -1
154
165
  begin
155
166
  run "ls #{deploy_to}/.git"
@@ -159,7 +170,9 @@ Capistrano::Configuration.instance(:must_exist).load do
159
170
  run "cd #{deploy_to} && git remote add origin #{repository}"
160
171
  end
161
172
  logger.level = 2
173
+
162
174
  run "cd #{deploy_to} && git fetch"
175
+
163
176
  if defined? "#{commit}"
164
177
  run "cd #{deploy_to} && git checkout #{commit} && git submodule update --init --recursive"
165
178
  else
data/obbistrano.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{obbistrano}
5
- s.version = "1.1.69"
5
+ s.version = "1.1.70"
6
6
  s.authors = ["Ross Riley", "One Black Bear"]
7
7
  s.date = Time.now
8
8
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: obbistrano
3
3
  version: !ruby/object:Gem::Version
4
- hash: 153
4
+ hash: 159
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 1
9
- - 69
10
- version: 1.1.69
9
+ - 70
10
+ version: 1.1.70
11
11
  platform: ruby
12
12
  authors:
13
13
  - Ross Riley
@@ -16,7 +16,7 @@ autorequire:
16
16
  bindir: bin
17
17
  cert_chain: []
18
18
 
19
- date: 2011-11-28 00:00:00 Z
19
+ date: 2011-11-29 00:00:00 Z
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
22
22
  name: capistrano