[utility] fix safe-rm condom on opensuse

This commit is contained in:
Matt Hamilton 2016-01-23 03:10:55 -05:00
parent 0dc32b8957
commit bb680b3742
1 changed files with 4 additions and 1 deletions

View File

@ -91,7 +91,10 @@ alias chown='chown --preserve-root -v'
# not aliasing rm -i, but if safe-rm is available, use condom.
if (( ${+commands[safe-rm]} )); then
alias rm='safe-rm'
# check that it's the condom safe-rm, not the 'abs path' safe-rm
if [[ $(file =safe-rm | grep 'perl') ]]; then
alias rm='safe-rm'
fi
fi