feat: add command.not-executable hook (closes #119)

pull/128/head
TorchedSammy 2022-03-16 19:45:55 -04:00
parent 20a4cdb505
commit 8b5dc69950
Signed by: sammyette
GPG Key ID: 904FC49417B44DCD
1 changed files with 1 additions and 0 deletions

View File

@ -142,6 +142,7 @@ func execCommand(cmd, old string) error {
err := lookpath(args[0])
if err == errNotExec {
hooks.Em.Emit("command.no-perm", args[0])
hooks.Em.Emit("command.not-executable", args[0])
return interp.NewExitStatus(126)
} else if err != nil {
hooks.Em.Emit("command.not-found", args[0])