Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/vanagon/cli/build.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class Build < Vanagon::CLI
-s, --skipcheck Skip the "check" stage when building components
-w, --workdir DIRECTORY Working directory on the local host,
managed automatically based on `keepwork` option
-k, --keepwork RULE Rule for preserving local `workdir`: [Default: never]
-k, --keepwork RULE Rule for preserving local `workdir`: [Default: on-failure]
always, on-success, on-failure, never
-v, --verbose Only here for backwards compatibility. Does nothing.

Expand Down
2 changes: 1 addition & 1 deletion lib/vanagon/driver.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ def initialize(platform, project, options = {}) # rubocop:disable Metrics/AbcSiz
@verbose = options[:verbose] || false
@preserve = options[:preserve] || :'on-failure'
@workdir = options[:workdir] || Dir.mktmpdir
@keepwork = options[:keepwork] || :never
@keepwork = options[:keepwork] || :'on-failure'

@@configdir = options[:configdir] || File.join(Dir.pwd, "configs")
components = options[:components] || []
Expand Down
4 changes: 2 additions & 2 deletions spec/lib/vanagon/cli_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@
subject = described_class.new
expect(subject.parse(%W[build hello project platform])).to include(:preserve => :'on-failure')
end
it "keepwork defaults to :never" do
it "keepwork defaults to :on-failure" do
subject = described_class.new
expect(subject.parse(%W[build hello project platform])).to include(:keepwork => :never)
expect(subject.parse(%W[build hello project platform])).to include(:keepwork => :'on-failure')
end
end

Expand Down
Loading