This commit is contained in:
Dylan Araps 2020-08-04 12:11:32 +03:00
parent 08ef84c948
commit 8edc56d3aa
No known key found for this signature in database
GPG Key ID: 46D62DD9F1DE636E
1 changed files with 2 additions and 1 deletions

3
shfm
View File

@ -28,11 +28,12 @@ file_escape() {
tmp=$1 safe=
# loop over string char by char
while [ "$tmp" ]; do
while :; do
c=${tmp%"${tmp#?}"*}
case $c in
[[:print:]]) safe=$safe$c ;;
'') return ;;
*) safe=$safe\? ;;
esac