fix stubexec

Fri, 26 Nov 2021 00:12:11 -0600

author
Meredith Howard <mhoward@roomag.org>
date
Fri, 26 Nov 2021 00:12:11 -0600
changeset 960
4921edc4b518
parent 959
4a5aaef00594
child 961
68baaab84a0c

fix stubexec

.lib/sh/stubexec.sh file | annotate | diff | comparison | revisions
--- a/.lib/sh/stubexec.sh
+++ b/.lib/sh/stubexec.sh
@@ -20,9 +20,10 @@ shim_filter() {
 }
 
 realbin() {
-  which -a $(basename $1) |
+  local bn="$(basename $1)"
+  which -a "$bn" |
     grep -v "$(realpath $1)" |
-    shim_filter |
+    shim_filter "$bn" |
     head -n 1
 }
 

mercurial