equal
deleted
inserted
replaced
31 # (^|.*/)$PREFIX.* |
31 # (^|.*/)$PREFIX.* |
32 fmri_abbrevs=( ${(M)_smf_fmris:#((#s)|*[/:])$PREFIX*} ) |
32 fmri_abbrevs=( ${(M)_smf_fmris:#((#s)|*[/:])$PREFIX*} ) |
33 |
33 |
34 # Go through the remaining elements and remove the characters |
34 # Go through the remaining elements and remove the characters |
35 # in front of $PREFIX. |
35 # in front of $PREFIX. |
36 for ((i = 1; i < $#fmri_abbrevs; i++ )); do |
36 for ((i = 1; i <= $#fmri_abbrevs; i++ )); do |
37 # Either one of these will work, but they're too |
37 # Either one of these will work, but they're too |
38 # greedy, preventing multiple matches below. |
38 # greedy, preventing multiple matches below. |
39 fmri_abbrevs[i]=${${fmri_abbrevs[i]}/((#s)|*[\/:])(#b)($PREFIX*)/$match[1]} |
39 fmri_abbrevs[i]=${${fmri_abbrevs[i]}/((#s)|*[\/:])(#b)($PREFIX*)/$match[1]} |
40 #fmri_abbrevs[i]=${${(M)${fmri_abbrevs[i]}:#(#b)((#s)|*/)$PREFIX*}#$match[1]} |
40 #fmri_abbrevs[i]=${${(M)${fmri_abbrevs[i]}:#(#b)((#s)|*/)$PREFIX*}#$match[1]} |
41 done |
41 done |