mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-21 11:31:15 -03:00
Move executable-check to C++
This was already apparently supposed to work, but didn't because we just overrode errno again. This now means that, if a correctly named candidate exists, we don't start the command-not-found handler. See #8804
This commit is contained in:
@@ -13,12 +13,6 @@ or set -g __fish_added_user_paths
|
||||
#
|
||||
function __fish_default_command_not_found_handler
|
||||
printf (_ "fish: Unknown command: %s\n") (string escape -- $argv[1]) >&2
|
||||
for file in $PATH/$argv[1]
|
||||
if test -e $file -a ! -x $file
|
||||
printf (_ "fish: %s exists but isn't executable\n") (string escape -- $file) >&2
|
||||
break
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user