forked from jan/debianmemberportfolio
fix path handling in keyringanalyzer
This commit is contained in:
parent
3e8f1f10e6
commit
3e0df60e17
1 changed files with 5 additions and 4 deletions
|
@ -31,6 +31,7 @@ import pkg_resources
|
||||||
import glob
|
import glob
|
||||||
import ConfigParser
|
import ConfigParser
|
||||||
import os
|
import os
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
|
||||||
def _get_keyrings():
|
def _get_keyrings():
|
||||||
|
@ -38,10 +39,10 @@ def _get_keyrings():
|
||||||
configured in ddportfolio.ini."""
|
configured in ddportfolio.ini."""
|
||||||
my_config = ConfigParser.ConfigParser()
|
my_config = ConfigParser.ConfigParser()
|
||||||
my_config.readfp(pkg_resources.resource_stream(__name__, 'ddportfolio.ini'))
|
my_config.readfp(pkg_resources.resource_stream(__name__, 'ddportfolio.ini'))
|
||||||
keyrings = glob.glob(my_config.get('DEFAULT', 'keyring.dir') +
|
keyringdir = os.path.expanduser(my_config.get('DEFAULT', 'keyring.dir'))
|
||||||
'/*.gpg')
|
print "keyrings dir %r" % keyringdir
|
||||||
keyrings.extend(glob.glob(my_config.get('DEFAULT', 'keyring.dir') +
|
keyrings = glob.glob(os.path.join(keyringdir, '*.gpg'))
|
||||||
'/*.pgp'))
|
keyrings.extend(glob.glob(os.path.join(keyringdir, '*.pgp')))
|
||||||
keyrings.sort()
|
keyrings.sort()
|
||||||
return keyrings
|
return keyrings
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue