summaryrefslogtreecommitdiff
path: root/oi.py
diff options
context:
space:
mode:
Diffstat (limited to 'oi.py')
-rwxr-xr-xoi.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/oi.py b/oi.py
index eb51c83..64dce16 100755
--- a/oi.py
+++ b/oi.py
@@ -1,8 +1,12 @@
-#!/usr/bin/env python
+#!/usr/bin/env python2
# Support offlineimap by retrieving login credentials and doing nametrans
import re, os
+from subprocess import check_output
+
+def get_pass_pass(account):
+ return check_output("pass " + account, shell=True).splitlines()[0]
def get_authinfo_password(machine, login, port):
s = "machine %s login %s password ([^ ]*) port %s" % (machine, login, port)