Also fix --hold not working if program to be executed is not found
This commit is contained in:
parent
185c3320a4
commit
7a156d5ef3
1 changed files with 4 additions and 0 deletions
|
|
@ -35,6 +35,10 @@ def hold(args: List[str]) -> None:
|
|||
ret = subprocess.Popen(args[1:]).wait()
|
||||
except KeyboardInterrupt:
|
||||
pass
|
||||
except FileNotFoundError:
|
||||
print(f'Could not find {args[1]!r} to execute', file=sys.stderr)
|
||||
except Exception as e:
|
||||
print(e, file=sys.stderr)
|
||||
from kitty.utils import hold_till_enter
|
||||
hold_till_enter()
|
||||
raise SystemExit(ret)
|
||||
|
|
|
|||
Loading…
Reference in a new issue