diff options
author | hut <hut@lepus.uberspace.de> | 2015-04-09 16:37:50 +0200 |
---|---|---|
committer | hut <hut@lepus.uberspace.de> | 2015-04-09 16:37:50 +0200 |
commit | 3c2862ea9b84d4f2e4ecd416c0db66db2dad58ba (patch) | |
tree | be12757cf6e0f373b16e9accc756db7bfc098131 /doc/examples | |
parent | e01be7133607697331b82d35476ac6131e110e1a (diff) | |
download | ranger-3c2862ea9b84d4f2e4ecd416c0db66db2dad58ba.tar.gz |
examples/bash_automatic_cd.sh: use mktemp
This is a follow-up to #282
Diffstat (limited to 'doc/examples')
-rw-r--r-- | doc/examples/bash_automatic_cd.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/doc/examples/bash_automatic_cd.sh b/doc/examples/bash_automatic_cd.sh index 8d72c553..465c9c80 100644 --- a/doc/examples/bash_automatic_cd.sh +++ b/doc/examples/bash_automatic_cd.sh @@ -8,7 +8,7 @@ # original directory. function ranger-cd { - tempfile='/tmp/chosendir' + tempfile="$(mktemp)" /usr/bin/ranger --choosedir="$tempfile" "${@:-$(pwd)}" test -f "$tempfile" && if [ "$(cat -- "$tempfile")" != "$(echo -n `pwd`)" ]; then |