mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-18 08:51:15 -03:00
function: restore '%self' functionality for --on-process-exit
One key use of process expansion, used in currently-shipped code, is for running a function on current shell exit. Restore the use of %self as a valid argument (and add `self`) and document this change. (faho: Remove bare "self")
This commit is contained in:
committed by
Fabian Homborg
parent
98d736f916
commit
21890ccac7
@@ -25,7 +25,10 @@ The following options are available:
|
||||
|
||||
- `-j PGID` or `--on-job-exit PGID` tells fish to run this function when the job with group ID PGID exits. Instead of PGID, the string 'caller' can be specified. This is only legal when in a command substitution, and will result in the handler being triggered by the exit of the job which created this command substitution.
|
||||
|
||||
- `-p PID` or `--on-process-exit PID` tells fish to run this function when the fish child process with process ID PID exits.
|
||||
- `-p PID` or `--on-process-exit PID` tells fish to run this function when the fish child process
|
||||
with process ID PID exits. Instead of a PID, for backward compatibility,
|
||||
"`%self`" can be specified as an alias for `$fish_pid`, and the function will be run when the
|
||||
current fish instance exits.
|
||||
|
||||
- `-s` or `--on-signal SIGSPEC` tells fish to run this function when the signal SIGSPEC is delivered. SIGSPEC can be a signal number, or the signal name, such as SIGHUP (or just HUP).
|
||||
|
||||
|
||||
Reference in New Issue
Block a user