Skip to content

Commit

Permalink
fix: really fix interactive help (#2743)
Browse files Browse the repository at this point in the history
  • Loading branch information
alecthomas authored Sep 20, 2024
1 parent 9d5f3ae commit 410b111
Showing 1 changed file with 9 additions and 7 deletions.
16 changes: 9 additions & 7 deletions frontend/cli/cmd_interactive.go
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,16 @@ func (i *interactiveCmd) Run(ctx context.Context, k *kong.Kong, projectConfig pr
errorf("%s", err)
continue
}
defer func() {
// Catch Exit() and continue the loop
if r := recover(); r != nil {
if r == errExitTrap { //nolint:errorlint
return
func() {
defer func() {
// Catch Exit() and continue the loop
if r := recover(); r != nil {
if r == errExitTrap { //nolint:errorlint
return
}
panic(r)
}
panic(r)
}
}()
kctx, err := k.Parse(args)
if err != nil {
errorf("%s", err)
Expand Down

0 comments on commit 410b111

Please sign in to comment.