mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-04-25 20:41:15 -03:00
implement status is-breakpoint
This implements `status is-breakpoint` that returns true if the current shell prompt is displayed in the context of a `breakpoint` command. This also fixes several bugs. Most notably making `breakpoint` a no-op if the shell isn't interactive. Also, typing `breakpoint` at an interactive prompt should be an error rather than creating a new nested debugging context. Partial fix for #1310
This commit is contained in:
@@ -6,6 +6,7 @@ status
|
||||
status is-login
|
||||
status is-interactive
|
||||
status is-block
|
||||
status is-breakpoint
|
||||
status is-command-substitution
|
||||
status is-no-job-control
|
||||
status is-full-job-control
|
||||
@@ -27,6 +28,8 @@ The following operations (sub-commands) are available:
|
||||
|
||||
- `is-block` returns 0 if fish is currently executing a block of code. Also `-b` or `--is-block`.
|
||||
|
||||
- `is-breakpoint` returns 0 if fish is currently showing a prompt in the context of a `breakpoint` command. See also the `fish_breakpoint_prompt` function.
|
||||
|
||||
- `is-interactive` returns 0 if fish is interactive - that is, connected to a keyboard. Also `-i` or `--is-interactive`.
|
||||
|
||||
- `is-login` returns 0 if fish is a login shell - that is, if fish should perform login tasks such as setting up the PATH. Also `-l` or `--is-login`.
|
||||
|
||||
Reference in New Issue
Block a user