shuttle 1.1.0 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/generators/shuttle/templates/shuttle.rb +7 -0
- data/lib/shuttle.rb +1 -1
- data/lib/shuttle/version.rb +1 -1
- data/lib/tasks/shuttle.rake +11 -1
- metadata +1 -1
data/lib/shuttle.rb
CHANGED
data/lib/shuttle/version.rb
CHANGED
data/lib/tasks/shuttle.rake
CHANGED
@@ -36,7 +36,9 @@ namespace :shuttle do
|
|
36
36
|
end
|
37
37
|
|
38
38
|
desc 'Launch the code to the space!'
|
39
|
-
task shuttle
|
39
|
+
task :shuttle, :stage do |t, args|
|
40
|
+
Rake::Task[:environment].invoke
|
41
|
+
|
40
42
|
if Shuttle.steps.blank?
|
41
43
|
require 'colored'
|
42
44
|
|
@@ -55,4 +57,12 @@ task shuttle: :environment do
|
|
55
57
|
Rake::Task[step].invoke
|
56
58
|
end
|
57
59
|
end
|
60
|
+
|
61
|
+
repository = Shuttle.stages[args[:stage].try(:to_sym)]
|
62
|
+
|
63
|
+
if repository.present?
|
64
|
+
p80("Executing deploy to #{args[:stage].to_s}...") do
|
65
|
+
sh "git push #{repository} HEAD:master -f"
|
66
|
+
end
|
67
|
+
end
|
58
68
|
end
|