mirror of
https://github.com/kemko/nomad.git
synced 2026-01-01 16:05:42 +03:00
Return evalID if -detach flag is passed to job revert (#13364)
* Return evalID if `-detach` flag is passed to job revert
This commit is contained in:
3
.changelog/13364.txt
Normal file
3
.changelog/13364.txt
Normal file
@@ -0,0 +1,3 @@
|
||||
```release-note:bug
|
||||
cli: Fixed a bug where the evaluation ID was not returned from `job revert` when the `-detach` flag was used
|
||||
``
|
||||
@@ -164,7 +164,13 @@ func (c *JobRevertCommand) Run(args []string) int {
|
||||
|
||||
// Nothing to do
|
||||
evalCreated := resp.EvalID != ""
|
||||
if detach || !evalCreated {
|
||||
|
||||
if !evalCreated {
|
||||
return 0
|
||||
}
|
||||
|
||||
if detach {
|
||||
c.Ui.Output("Evaluation ID: " + resp.EvalID)
|
||||
return 0
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user