Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
P
packer
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kristopher Ruzic
packer
Commits
496d1fe9
Commit
496d1fe9
authored
Dec 13, 2014
by
Seth Vargo
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1756 from StefanScherer/fix/packer-minus-minus-version
fixed `packer --version` to show version again
parents
88d48151
8b10e70b
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
6 deletions
+7
-6
main.go
main.go
+1
-0
test/cli.bats
test/cli.bats
+6
-6
No files found.
main.go
View file @
496d1fe9
...
...
@@ -166,6 +166,7 @@ func wrappedMain() int {
Commands
:
Commands
,
HelpFunc
:
cli
.
BasicHelpFunc
(
"packer"
),
HelpWriter
:
os
.
Stdout
,
Version
:
Version
,
}
exitCode
,
err
:=
cli
.
Run
()
...
...
test/cli.bats
View file @
496d1fe9
...
...
@@ -17,20 +17,20 @@ load test_helper
[[ "$output" == *"Packer v"* ]]
run packer -v
[ "$status" -eq
0
]
[[ "$output" =
= *"Packer v"*
]]
[ "$status" -eq
1
]
[[ "$output" =
~ ([0-9]+\.[0-9]+)
]]
run packer --version
[ "$status" -eq
0
]
[[ "$output" =
= *"Packer v"*
]]
[ "$status" -eq
1
]
[[ "$output" =
~ ([0-9]+\.[0-9]+)
]]
}
@test "cli: packer version show help" {
run packer version -h
[ "$status" -eq 0 ]
[[ "$output" == *"
usage: packer version
"* ]]
[[ "$output" == *"
Packer v
"* ]]
run packer version --help
[ "$status" -eq 0 ]
[[ "$output" == *"
usage: packer version
"* ]]
[[ "$output" == *"
Packer v
"* ]]
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment