diff --git a/cmd/internal/common/exit.go b/cmd/internal/common/exit.go index 9b912ddc..d38f27e0 100644 --- a/cmd/internal/common/exit.go +++ b/cmd/internal/common/exit.go @@ -46,5 +46,6 @@ func ExitOnErr(cmd *cobra.Command, errFmt string, err error) { } cmd.PrintErrln(err) + cmd.PersistentPostRun(cmd, nil) os.Exit(code) }