mirror of
https://github.com/fish-shell/fish-shell.git
synced 2024-11-23 18:30:20 +08:00
dfa73c7cc1
darcs-hash:20061025202836-ac50b-682015e2f5830a85ff520e89b0a951ca9d2913dc.gz
16 lines
307 B
Fish
16 lines
307 B
Fish
#
|
|
# This function deletes a character from the commandline if it is
|
|
# non-empty, and exits the shell otherwise. Implementing this
|
|
# functionality has been a longstanding request from various
|
|
# fish-users.
|
|
#
|
|
|
|
function delete-or-exit
|
|
if test (commandline)
|
|
commandline -f delete-char
|
|
else
|
|
exit
|
|
end
|
|
end
|
|
|