Permalink
Browse files

Update mutt/offlineimap.py

replaced sjl username with `whoami` for general purpose user detection
  • Loading branch information...
1 parent deee914 commit 6c5395ce696901bc35d0ce15c65833e09c9f54d6 @fpischedda fpischedda committed Oct 2, 2012
Showing with 2 additions and 2 deletions.
  1. +2 −2 mutt/offlineimap.py
View
@@ -6,9 +6,9 @@ def get_keychain_pass(account=None, server=None):
'command': 'find-internet-password',
'account': account,
'server': server,
- 'keychain': '/Users/sjl/Library/Keychains/login.keychain',
+ 'keychain': '/Users/`whoami`/Library/Keychains/login.keychain',
}
- command = "sudo -u sjl %(security)s -v %(command)s -g -a %(account)s -s %(server)s %(keychain)s" % params
+ command = "sudo -u `whoami` %(security)s -v %(command)s -g -a %(account)s -s %(server)s %(keychain)s" % params
output = subprocess.check_output(command, shell=True, stderr=subprocess.STDOUT)
outtext = [l for l in output.splitlines()
if l.startswith('password: ')][0]

0 comments on commit 6c5395c

Please sign in to comment.