您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

1234567891011
  1. import os.path
  2. import subprocess
  3. home = os.path.expanduser("~")
  4. def mailpasswd(acct):
  5. acct = os.path.basename(acct)
  6. path = "%s/.local/share/muttwizard/%s.gpg" % (home,acct)
  7. args = ["gpg2", "--use-agent", "--quiet", "--batch", "-d", path]
  8. try:
  9. return subprocess.check_output(args).strip().decode('UTF-8')
  10. except subprocess.CalledProcessError:
  11. return ""