projects
/
matthijs
/
upstream
/
backupninja.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
89f2ff733918e888fc79a2f927252ee63e8bd346
[matthijs/upstream/backupninja.git]
/
lib
/
tools.in
1
#!@BASH@
2
3
4
#
5
# create a temporary file in a secure way.
6
#
7
function maketemp() {
8
if [ -x /bin/mktemp ]
9
then
10
local tempfile=`mktemp /tmp/$1.XXXXXXXX`
11
else
12
DATE=`date`
13
sectmp=`echo $DATE | /usr/bin/md5sum | cut -d- -f1`
14
local tempfile=/tmp/$1.$sectmp
15
fi
16
echo $tempfile
17
}
18
19