fix: Fix double shim creating when non-empty sbin'' ice.

Currently, e.g. following command:

```zsh
zi sbin'dstask*->tsk' bpick'dstask-linux-amd*' ghapi from'gh-r' for dstask
```

Will create two shims, `tsk` and 'dstask-linux-amd64'.
This commit is contained in:
Sebastian Gniazdowski 2022-12-28 11:35:29 +00:59
parent 6e8f94f7c4
commit 6ba1123181

View file

@ -150,13 +150,14 @@ if (( ${+ICE[sbin]} )) {
local -a sbins srcdst
sbins=( ${(s.;.)ICE[sbin]} )
(( !$#sbins )) && sbins+=("")
local sbin
(
# CD for the globbing through eval
builtin cd -q "$dir" || return
for sbin ( $sbins "" ) {
for sbin ( $sbins ) {
integer set_gem_home=0 set_node_path=0 set_virtualenv=0 set_cwd=0 \
use_all_null=0 use_err_null=0 use_out_null=0
@ -220,6 +221,7 @@ if (( ${+ICE[sbin]} )) {
builtin print -r -- "$REPLY" \
>! "$file.cmd"
command chmod +x "$file.cmd"
continue
fi
.za-bgn-bin-or-src-function-body 0 \