@@ -193,19 +193,19 @@ OUT_FILE=$OLD_PWD # assume "this directory" without a name change by default
193
193
194
194
if [ ! -z " $1 " ]; then
195
195
OUT_FILE=" $1 "
196
- if [ " -" == $OUT_FILE ]; then
196
+ if [ " -" == " $OUT_FILE " ]; then
197
197
SEPARATE=0
198
198
fi
199
199
shift
200
200
fi
201
201
202
202
# Validate parameters; error early, error often.
203
- if [ " -" == $OUT_FILE -o $SEPARATE -ne 1 ] && [ " $FORMAT " == " tar" -a ` $TARCMD --help | grep -q -- " --concatenate" ; echo $? ` -ne 0 ]; then
203
+ if [ " -" == " $OUT_FILE " -o $SEPARATE -ne 1 ] && [ " $FORMAT " == " tar" -a ` $TARCMD --help | grep -q -- " --concatenate" ; echo $? ` -ne 0 ]; then
204
204
echo " Your 'tar' does not support the '--concatenate' option, which we need"
205
205
echo " to produce a single tarfile. Either install a compatible tar (such as"
206
206
echo " gnutar), or invoke $PROGRAM with the '--separate' option."
207
207
exit
208
- elif [ $SEPARATE -eq 1 -a ! -d $OUT_FILE ]; then
208
+ elif [ $SEPARATE -eq 1 -a ! -d " $OUT_FILE " ]; then
209
209
echo " When creating multiple archives, your destination must be a directory."
210
210
echo " If it's not, you risk being surprised when your files are overwritten."
211
211
exit
@@ -265,7 +265,7 @@ if [ $VERBOSE -eq 1 ]; then
265
265
echo -n " concatenating archives into single archive..."
266
266
fi
267
267
# Concatenate archives into a super-archive.
268
- if [ $SEPARATE -eq 0 -o " -" == $OUT_FILE ]; then
268
+ if [ $SEPARATE -eq 0 -o " -" == " $OUT_FILE " ]; then
269
269
if [ $FORMAT == ' tar.gz' ]; then
270
270
gunzip $superfile
271
271
superfile=${superfile: 0: -3} # Remove '.gz'
@@ -299,7 +299,7 @@ if [ $VERBOSE -eq 1 ]; then
299
299
echo -n " moving archive to $OUT_FILE ..."
300
300
fi
301
301
while read file; do
302
- if [ " -" == $OUT_FILE ]; then
302
+ if [ " -" == " $OUT_FILE " ]; then
303
303
cat " $file " && rm -f " $file "
304
304
else
305
305
mv " $file " " $OUT_FILE "
0 commit comments