可以远程致力于github

发布于 2025-01-25 08:18:15 字数 1347 浏览 2 评论 0原文

我一直在尝试从VScode创建一个存储库,但因此,我不得不遵循GitHub的默认方式来创建和推动提交。它引发的错误 - :

git -c user.useConfigOnly=true commit --quiet --allow-empty-message --file - -S
gpg: skipped "digambernegi <digambernegi001.com>": No secret key   
gpg: signing failed: No secret key
error: gpg failed to sign the data
fatal: failed to write commit object

git log

[2022-05-01T07:41:58.034Z] > git config --get-all user.name [104ms]
[2022-05-01T07:41:58.144Z] > git config --get-all user.email [104ms]
[2022-05-01T07:42:03.415Z] > git ls-files --stage -- 
C:\Users\Nagi\Downloads\multinavbar\index.html [128ms]
[2022-05-01T07:42:03.667Z] > git cat-file -s a8491a2abe471cef2354da09d005227a8725f831 [210ms]
[2022-05-01T07:42:06.503Z] > git ls-files --stage -- 
C:\Users\Nagi\Downloads\multinavbar\index.html [106ms]
[2022-05-01T07:42:06.631Z] > git cat-file -s a8491a2abe471cef2354da09d005227a8725f831 [120ms]
[2022-05-01T07:42:08.633Z] > git -c user.useConfigOnly=true commit --quiet --allow-empty- 
message --file - -S [282ms]
[2022-05-01T07:42:08.633Z] gpg: skipped "digambernegi <digambernegi001.com>": No secret key
gpg: signing failed: No secret key
error: gpg failed to sign the data
fatal: failed to write commit object

我要实现的目标是我可以轻松地创建一个存储库,并将其仅从vscode将其推向github并提交所有其他以后的更改。

I have been trying to create a repository from VScode but couldn't therefore I had to follow Github's default way of creating and pushing commits manually. The error it throws-:

git -c user.useConfigOnly=true commit --quiet --allow-empty-message --file - -S
gpg: skipped "digambernegi <digambernegi001.com>": No secret key   
gpg: signing failed: No secret key
error: gpg failed to sign the data
fatal: failed to write commit object

Git Log

[2022-05-01T07:41:58.034Z] > git config --get-all user.name [104ms]
[2022-05-01T07:41:58.144Z] > git config --get-all user.email [104ms]
[2022-05-01T07:42:03.415Z] > git ls-files --stage -- 
C:\Users\Nagi\Downloads\multinavbar\index.html [128ms]
[2022-05-01T07:42:03.667Z] > git cat-file -s a8491a2abe471cef2354da09d005227a8725f831 [210ms]
[2022-05-01T07:42:06.503Z] > git ls-files --stage -- 
C:\Users\Nagi\Downloads\multinavbar\index.html [106ms]
[2022-05-01T07:42:06.631Z] > git cat-file -s a8491a2abe471cef2354da09d005227a8725f831 [120ms]
[2022-05-01T07:42:08.633Z] > git -c user.useConfigOnly=true commit --quiet --allow-empty- 
message --file - -S [282ms]
[2022-05-01T07:42:08.633Z] gpg: skipped "digambernegi <digambernegi001.com>": No secret key
gpg: signing failed: No secret key
error: gpg failed to sign the data
fatal: failed to write commit object

What I want to achieve is I can easily create a repository and push it to Github from vsCode only and commit all other later changes.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

情魔剑神 2025-02-01 08:18:15

如果需要提交签名,则需要先检查一下。

如果没有,请检查您是否 git config -global commit.gpgsign 设置为true,因为这可以解释为什么VSCODE试图签署您的提交。

将其设置为False将允许您测试VSCODE是否可以越过此阶段,并在新的本地存储库中创建您的提交。

You need to check first if you need commit signing.

If not, check if you have git config --global commit.gpgsign set to true, because that would explain why VSCode is trying to sign your commit.

Setting it to false would allow you to test if VSCode can get past this stage, and create your commit in your new local repository.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文