Use printf instead of echo

This commit is contained in:
Víctor Lasa 2020-03-29 16:42:33 +00:00 committed by GitHub
parent afc087b170
commit 9658ece723
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -9,7 +9,7 @@
# Location of link to wallpaper.
bgloc="${XDG_CACHE_HOME:-$HOME/.cache/}bg"
[ ! -L "$bgloc" ] && [ ! -e "$1" ] && echo 'Please provide a valid image or directory.' && exit 1
[ ! -L "$bgloc" ] && [ ! -e "$1" ] && printf 'Please provide a valid image or directory.\n' && exit 1
[ -f "$1" ] && ln -sf "$(readlink -f "$1")" "$bgloc"