gpg and double quotation mark problem
mailinglisten at hauke-laging.de
Mon Mar 4 03:01:06 CET 2013
Am So 03.03.2013, 15:39:49 schrieb Shaoping Xie:
> I am working on a script to automate the encryption process and have encountered a strange problem:
> Line 1: $GPG "$ADDITIONALOPTIONS" -r "$GPGKEY" -o "$OUTPUTFILE" -e "$INPUTFILE"
> Line 2: $GPG $ADDITIONALOPTIONS -r $GPGKEY -o $OUTPUTFILE -e $INPUTFILE
This is not strange at all as you encounter the same behaviour with more or
less all programs (i.e. this problem is not related to GnuPG at all). Usually
a program requires so see --arg1 and --arg2 as seperate options. "" makes the
shell pass both as one string. That usually doesn't make sense to the program
(and even worse: if it does then it's most probably not the intended sense).
PGP: 7D82 FB9F D25A 2CE4 5241 6C37 BF4B 8EEF 1A57 1DF5 (seit 2012-11-04)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 572 bytes
Desc: This is a digitally signed message part.
More information about the Gnupg-users