Skip to content

Commit

Permalink
fix: Restore exit code on upgrade check command
Browse files Browse the repository at this point in the history
  • Loading branch information
matbme committed Dec 22, 2023
1 parent 79a1a2a commit aac9093
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion cmd/upgrade.go
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,11 @@ func upgrade(cmd *cobra.Command, args []string) error {
fmt.Println(string(out))
}

return nil
if !res && sumChanges == 0 {
os.Exit(1) // No update available
} else {
os.Exit(0) // Update available
}
}

if !core.RootCheck(false) {
Expand Down

0 comments on commit aac9093

Please sign in to comment.