sbopkg, slapt-{get,src}: expand tilde in config file name
This fixes following [[ -r "$config" ]] when file name begins with ~.
This commit is contained in:
parent
154f388413
commit
505481c8cc
@ -40,6 +40,7 @@ _sbopkg()
|
||||
for (( i=${#words[@]}-1; i>0; i-- )); do
|
||||
if [[ "${words[i]}" == -f ]]; then
|
||||
config="${words[i+1]}"
|
||||
__expand_tilde_by_ref config
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
@ -45,6 +45,7 @@ _slapt_get()
|
||||
for (( i=${#words[@]}-1; i>0; i-- )); do
|
||||
if [[ ${words[i]} == -@(c|-config) ]]; then
|
||||
config="${words[i+1]}"
|
||||
__expand_tilde_by_ref config
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
@ -41,6 +41,7 @@ _slapt_src()
|
||||
for (( i=${#words[@]}-1; i>0; i-- )); do
|
||||
if [[ ${words[i]} == -@(c|-config) ]]; then
|
||||
config="${words[i+1]}"
|
||||
__expand_tilde_by_ref config
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
Loading…
x
Reference in New Issue
Block a user