如何在 `git rebase –continue` 中禁用 GPG 签名?

huangapple go评论58阅读模式
英文:

How do I disable GPG signing for `git rebase --continue`?

问题

我正在尝试重新定位一个分支。我的GPG/SSH代理设置出了问题 - git rebase --continue 尝试签署提交并失败。

我已经尽力禁用GPG,但没有任何效果。git rebase --continue --no-gpg-sign 打印出重新定位的帮助消息,更改配置文件和/或添加 -c commit.gpgSign=false 也没有效果。

英文:

I am attempting to rebase a branch. My GPG/SSH agent setup is broken - git rebase --continue attempts to sign the commit and fails.

I have done everything I can think of to disable GPG and nothing is working. git rebase --continue --no-gpg-sign prints out rebase's help message, and changing config files and/or adding -c commit.gpgSign=false has no effect.

答案1

得分: 1

  1. 我不得不重新启动 rebase:
    1. 使用 git rebase --abort 取消当前的 rebase。
    2. 再次运行 rebase,这次要 添加 --no-gpg-sign
    3. 解决冲突等。
    4. 现在可以运行 git rebase --continue

显然,GPG/SSH 设置被初始 rebase 命令所锁定,并且后续的 rebase 操作(或者至少是 git rebase --continue)不会考虑配置更改 - 它们会锁定到初始 rebase 时使用的设置。

英文:

I had to restart the rebase:

  1. git rebase --abort to cancel the current rebase.
  2. Run the rebase again, adding --no-gpg-sign this time.
  3. Resolve conflicts, etc.
  4. git rebase --continue works now.

Evidently GPG/SSH settings are 'locked in' by the initial rebase command and subsequent rebase operations (or at least git rebase --continue) do not respect configuration changes - they are locked into the settings used for the initial rebase.

huangapple
  • 本文由 发表于 2023年7月12日 23:47:52
  • 转载请务必保留本文链接:https://go.coder-hub.com/76672386.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定