mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-09-26 18:01:03 +02:00
zsh-workers/8906
This commit is contained in:
parent
a0559fd2b6
commit
5f61b262a5
1 changed files with 3 additions and 3 deletions
|
@ -39,10 +39,10 @@ while getopts "P:S:qr:R:W:F:J:V:X:f/g:M:" opt; do
|
|||
;;
|
||||
W) tmp1="$OPTARG"
|
||||
if [[ "$tmp1[1]" = '(' ]]; then
|
||||
prepaths=( ${^=tmp1[2,-2]}/ )
|
||||
prepaths=( ${^=tmp1[2,-2]%/}/ )
|
||||
else
|
||||
prepaths=( ${(P)=${tmp1}} )
|
||||
(( ! $#prepaths )) && prepaths=( ${tmp1}/ )
|
||||
prepaths=( ${(P)^=tmp1%/}/ )
|
||||
(( ! $#prepaths )) && prepaths=( ${tmp1%/}/ )
|
||||
fi
|
||||
(( ! $#prepaths )) && prepaths=( '' )
|
||||
;;
|
||||
|
|
Loading…
Reference in a new issue