Commit 4536ef7b authored by Giorgos Korfiatis's avatar Giorgos Korfiatis Committed by Efthymia Bika

Pass gpg homedir option to duplicity

parent c51bafae
......@@ -74,6 +74,7 @@ patch -N -p0 < $ROOTPATH/src/duplicity-patches/timeview.patch
patch -N -p0 < $ROOTPATH/src/duplicity-patches/syspath.patch
patch -N -p0 < $ROOTPATH/src/duplicity-patches/cacert.patch
patch -N -p0 < $ROOTPATH/src/duplicity-patches/setrlimit.patch
patch -N -p0 < $ROOTPATH/src/duplicity-patches/gpg_homedir.patch
LIBRSYNC_DIR=/usr/local python setup.py build --executable="/usr/bin/env python"
cd build/lib.*
cp -pr * $DUPL/lib
......
=== modified file 'duplicity/commandline.py'
--- duplicity/commandline.py 2016-02-10 17:15:49 +0000
+++ duplicity/commandline.py 2016-03-04 13:32:51 +0000
@@ -398,6 +398,8 @@
parser.add_option("--gpg-binary", type="file", metavar=_("path"))
+ parser.add_option("--gpg-homedir", metavar=_("path"))
+
parser.add_option("--gpg-options", action="extend", metavar=_("options"))
# TRANSL: Used in usage help to represent an ID for a hidden GnuPG key. Example:
=== modified file 'duplicity/globals.py'
--- duplicity/globals.py 2015-10-10 00:02:35 +0000
+++ duplicity/globals.py 2016-03-04 13:33:18 +0000
@@ -88,6 +88,9 @@
# Options to pass to gpg
gpg_options = ''
+# Option 'homedir' to pass to gpg
+gpg_homedir = ''
+
# Maximum file blocksize
max_blocksize = 2048
=== modified file 'duplicity/gpg.py'
--- duplicity/gpg.py 2015-11-05 15:36:58 +0000
+++ duplicity/gpg.py 2016-03-04 13:35:50 +0000
@@ -124,6 +124,9 @@
if globals.gpg_options:
for opt in globals.gpg_options.split():
gnupg.options.extra_args.append(opt)
+ if globals.gpg_homedir:
+ gnupg.options.extra_args.append('--homedir')
+ gnupg.options.extra_args.append(globals.gpg_homedir)
cmdlist = []
if profile.sign_key:
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment