From d3443a2a8ac5ca99fff8b77b0fbd4f3812c6f5f1 Mon Sep 17 00:00:00 2001 From: Matthias Rampke Date: Tue, 26 Jun 2012 20:04:50 +0200 Subject: [PATCH] specify template to mktemp(1) mktemp(1) is not specified by POSIX and accordingly inconsistent across systems - e.g. non-GNU-implementations requiring that there be some sort of template specified. this appears to be the simplest more-or-less portable invocation. use the user name as part of the name for temporary files. --- fetch-tweets.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fetch-tweets.sh b/fetch-tweets.sh index 8a0331b..8b5710e 100755 --- a/fetch-tweets.sh +++ b/fetch-tweets.sh @@ -36,8 +36,8 @@ do echo $1 tweet total "$twitter_total" is greater than the already saved "$saved" echo Trying to get $(($twitter_total - $saved)) -temp=$(mktemp) -temp2=$(mktemp) +temp=$(mktemp "$1.XXXX") +temp2=$(mktemp "$1.XXXX") url="${api}screen_name=${1}&count=200&page=${page}${since}&include_rts=true&trim_user=1&include_entities=1"