在gpg安装目录(mac的是~/.gnup)下建立两个配置文件:gpg.conf、gpg-agent.conf gpg.conf use-agent pinentry-mode loopback gpg-agent.conf allow-loopback-pinentry