Skip to content

Commit 4158ed7

Browse files
committed
rm temp file on failure
1 parent 051a071 commit 4158ed7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

cli/support.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ func (r *RootCmd) support() *clibase.Cmd {
8686
}
8787

8888
if err := writeBundle(bun, zwr); err != nil {
89+
_ = os.Remove(outputPath) // best effort
8990
return xerrors.Errorf("write support bundle to %s: %w", outputPath, err)
9091
}
9192
return nil

0 commit comments

Comments
 (0)