Merge branch 'fix/76-verbose-flag-order' into develop

fix/74-no-HOME-env
Isis Lovecruft 2014-11-19 04:29:22 +00:00
commit 899d429f7a
No known key found for this signature in database
GPG Key ID: 18C16EC5F9F1D673
1 changed files with 8 additions and 5 deletions

View File

@ -500,11 +500,9 @@ class GPGBase(object):
if self.use_agent: cmd.append('--use-agent')
else: cmd.append('--no-use-agent')
if self.options:
[cmd.append(opt) for opt in iter(_sanitise_list(self.options))]
if args:
[cmd.append(arg) for arg in iter(_sanitise_list(args))]
# The arguments for debugging and verbosity should be placed into the
# cmd list before the options/args in order to resolve Issue #76:
# https://github.com/isislovecruft/python-gnupg/issues/76
if self.verbose:
cmd.append('--debug-all')
@ -517,6 +515,11 @@ class GPGBase(object):
else:
cmd.append('--debug-level %s' % self.verbose)
if self.options:
[cmd.append(opt) for opt in iter(_sanitise_list(self.options))]
if args:
[cmd.append(arg) for arg in iter(_sanitise_list(args))]
return cmd
def _open_subprocess(self, args=None, passphrase=False):