【问题标题】:Unable to use Gcommit (Fugitive Plugin) on Vim when signing commits签署提交时无法在 Vim 上使用 Gcommit (Fugitive Plugin)
【发布时间】:2017-03-28 19:24:53
【问题描述】:

上下文

自从我决定签署所有提交后,每当我尝试运行 :Gcommit 并编写提交消息时,我都会收到:

fugitive: error: failed to sign the data

我尝试了人们在 [this other question] (gpg failed to sign the data fatal: failed to write commit object [Git 2.10.0]) 和 this other one 上提出的所有建议,但显然,这只是一个不同的错误。

查看issues on the Fugitive repository,我注意到一个打开 issue 非常接近我所经历的但没有答案。

  • GPG 通过brew 安装。
  • GPG 代理 已安装并正在运行。
  • 使用 Vim 而不是 Neovim
  • 所有符号链接均已正确设置。

问题

如何在 Vim 中使用 Fugitive 和 GPG 签署提交?

【问题讨论】:

    标签: git macos vim gnupg vim-fugitive


    【解决方案1】:

    在忽略此功能数月后,我终于找到了解决此问题的方法!

    答案在this link,感谢“Blimmer”: git config --global gpg.program $(which gpg) echo "no-tty" >> ~/.gnupg/gpg.conf

    它对我有用!

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2013-02-28
      • 1970-01-01
      • 1970-01-01
      • 2014-10-06
      • 2019-02-03
      • 2013-05-17
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多