Skip to content
This repository was archived by the owner on Feb 28, 2019. It is now read-only.

Commit 6ba93e1

Browse files
committed
Add mechanism via which release process can terminate at a particular stage
1 parent 8212d7d commit 6ba93e1

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

tasks/release.rake

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@ def stage(stage_name, description, options = {})
2424
elsif !ENV['STAGE'].nil?
2525
puts "Skipping Stage: #{stage_name} - #{description}"
2626
end
27+
if ENV['LAST_STAGE'] == stage_name
28+
ENV['STAGE'] = ENV['LAST_STAGE']
29+
end
2730
end
2831

2932
desc 'Perform a release'
@@ -126,6 +129,10 @@ HEADER
126129
end
127130

128131
if ENV['STAGE']
129-
raise "Invalid STAGE specified '#{ENV['STAGE']}' that did not match any stage"
132+
if ENV['LAST_STAGE'] == ENV['STAGE']
133+
puts "LAST_STAGE specified '#{ENV['LAST_STAGE']}', later stages were skipped"
134+
else
135+
raise "Invalid STAGE specified '#{ENV['STAGE']}' that did not match any stage"
136+
end
130137
end
131138
end

0 commit comments

Comments
 (0)