国产 无码 综合区,色欲AV无码国产永久播放,无码天堂亚洲国产AV,国产日韩欧美女同一区二区

解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.

這篇具有很好參考價值的文章主要介紹了解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.。希望對大家有所幫助。如果存在錯誤或未考慮完全的地方,請大家不吝賜教,您也可以點擊"舉報違法"按鈕提交疑問。

1.首先,判斷是否生成了密鑰和公鑰

1.打開Git Bash。

2.輸入ls -al ~/.ssh以查看是否存在現(xiàn)有 SSH 密鑰。

3.檢查目錄列表以查看您是否已有公共 SSH 密鑰。默認情況下,GitHub 支持的公鑰的文件名是以下之一:id_rsa.pub、id_ecdsa.pub、id_ed25519.pub。

2.沒有生成密鑰,如果已有密鑰請忽略這一步?;蛘吣憧梢园创瞬僮髦匦律梢粋€

如果您收到~/.ssh不存在的錯誤,則說明您在默認位置中沒有現(xiàn)有的 SSH 密鑰對,需要創(chuàng)建新的 SSH 密鑰對,具體見下一節(jié),這里先討論有密鑰對的情況。

1.打開Git Bash

2.粘貼下面的文本,替換為您的 GitHub 電子郵件地址。

ssh-keygen -t ed25519 -C "your_email@example.com"

(這將使用提供的電子郵件作為標(biāo)簽創(chuàng)建一個新的 SSH 密鑰。

? ?注意:如果您使用的是不支持 Ed25519 算法的舊系統(tǒng),請使用:

ssh-keygen -t rsa -b 4096 -C "your_email@example.com"

)?

?3.在出現(xiàn)提示時,鍵入安全密碼

> Enter passphrase (empty for no passphrase): [Type a passphrase]
> Enter same passphrase again: [Type passphrase again]

?3.將密鑰加入ssh-agent

1.如果您看到列出了想要用來連接到 GitHub 的現(xiàn)有公鑰和私鑰對(例如id_rsa.pubid_rsa ),則可以將該密鑰添加到 ssh-agent。

2.將密鑰添加到ssh-agent

$ eval "$(ssh-agent -s)"

3.將您的 SSH 私鑰添加到 ssh-agent。如果您使用不同的名稱創(chuàng)建了密鑰,或者要添加具有不同名稱的現(xiàn)有密鑰,請將命令中的id_ed25519替換為您的私鑰文件的名稱。

ssh-add ~/.ssh/id_ed25519

?(注:如果您使用的是 macOS 或 Linux,則可能需要在生成新的 SSH 密鑰之前更新 SSH 客戶端或安裝新的 SSH 客戶端。

將硬件安全密鑰插入計算機。

打開Git Bash

粘貼下面的文本,替換您在 GitHub 上帳戶的電子郵件地址。

ssh-keygen -t ed25519-sk -C "YOUR_EMAIL"

如果命令失敗并且您收到錯誤invalid format,或者feature not supported,您可能正在使用不支持 Ed25519 算法的硬件安全密鑰。請輸入以下命令。

ssh-keygen -t ecdsa-sk -C "your_email@example.com"

出現(xiàn)提示時,請觸摸硬件安全密鑰上的按鈕。

當(dāng)系統(tǒng)提示您“輸入要保存密鑰的文件”時,按 Enter 接受默認文件位置。

> Enter a file in which to save the key (/c/Users/YOU/.ssh/id_ed25519_sk):[Press enter]

?當(dāng)系統(tǒng)提示您輸入密碼時,請按Enter。

> Enter passphrase (empty for no passphrase): [Type a passphrase]
> Enter same passphrase again: [Type passphrase again]

?)

4.將 SSH 公鑰添加到您在 GitHub 上的帳戶。

$ clip < ~/.ssh/id_ed25519.pub

(如果你的 SSH 公鑰文件的名稱與示例代碼不同,請修改文件名以匹配您當(dāng)前的設(shè)置。復(fù)制密鑰時,請勿添加任何換行符或空格。 )

5.在任意頁面的右上角,點擊您的個人資料照片,然后點擊“設(shè)置”。

解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.,git,github

6.在側(cè)邊欄的“訪問”部分中,單擊SSH 和 GPG 密鑰。?

解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.,git,github

7.單擊新建 SSH 密鑰或添加 SSH 密鑰。

解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.,git,github

8.在“標(biāo)題”字段中,為新密鑰添加描述性標(biāo)簽。

解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.,git,github

9.選擇密鑰類型,身份驗證或簽名。

解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.,git,github選擇身份認證?

10.在“密鑰”字段中,粘貼您的公鑰。

解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.,git,github

11.單擊添加 SSH 密鑰。

4.測試ssh連接

1.打開Git Bash。

2.輸入以下內(nèi)容:

$ ssh -T git@github.com

您可能會看到這樣的警告:

> The authenticity of host 'github.com (IP ADDRESS)' can't be established.
> ED25519 key fingerprint is SHA256:+DiY3wvvV6TuJJhbpZisF/zLDA0zPMSvHdkr4UvCOqU.
> Are you sure you want to continue connecting (yes/no)?

?3.驗證您看到的消息中的指紋是否與GitHub 的公鑰指紋匹配。如果是,則輸入yes

公鑰指紋在你將公鑰加入github的時候會顯示,如下圖:解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.,git,github

)?

> Hi USERNAME! You've successfully authenticated, but GitHub does not
> provide shell access.

出現(xiàn)此語句,說明成功?,就可以上傳代碼了。文章來源地址http://www.zghlxwxcb.cn/news/detail-659161.html

到了這里,關(guān)于解決git@github.com:Permission denied (publickey).fatal:Could not read from remote repository.的文章就介紹完了。如果您還想了解更多內(nèi)容,請在右上角搜索TOY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!

本文來自互聯(lián)網(wǎng)用戶投稿,該文觀點僅代表作者本人,不代表本站立場。本站僅提供信息存儲空間服務(wù),不擁有所有權(quán),不承擔(dān)相關(guān)法律責(zé)任。如若轉(zhuǎn)載,請注明出處: 如若內(nèi)容造成侵權(quán)/違法違規(guī)/事實不符,請點擊違法舉報進行投訴反饋,一經(jīng)查實,立即刪除!

領(lǐng)支付寶紅包贊助服務(wù)器費用

相關(guān)文章

  • git 報錯:git@github.com: Permission denied (publickey).fatal: 無法讀取遠程倉庫。

    起因: 我輸入git push -u origin master 想要push到github 顯示 git@github.com: Permission denied (publickey). fatal: 無法讀取遠程倉庫。 請確認您有正確的訪問權(quán)限并且倉庫存在。 那么我們 第一步: 檢查SSH密鑰配置不正確: 確保你的本地計算機上配置了正確的 SSH 密鑰。你可以通過以下步驟檢

    2024年02月04日
    瀏覽(22)
  • 解決git@github.com:Permission denied (publickey). Could not read from remote repository. Please make s

    解決git@github.com:Permission denied (publickey). Could not read from remote repository. Please make s

    這個錯誤通常表示沒有正確的權(quán)限來訪問該 Git 倉庫。 為了解決GitHub上的權(quán)限問題,需要執(zhí)行以下步驟: 打開命令行終端(例如Git Bash)并輸入以下命令: 將公鑰添加到GitHub帳戶中, 執(zhí)行以下步驟: 在“Title”字段中為新密鑰提供一個描述性標(biāo)題。 將“Key”字段中的公鑰粘

    2024年02月06日
    瀏覽(56)
  • git克隆報錯:Permission denied (publickey).fatal: Could not read from remote repository解決辦法

    git克隆報錯:Permission denied (publickey).fatal: Could not read from remote repository解決辦法

    Permission denied (publickey).fatal: Could not read from remote repository 1、問題解決首先參考文章 例如:缺少公鑰解決辦法 2、生成公鑰報錯 ssh-keygen -t rsa -C ‘郵箱’ 生成公鑰時,報錯如下: 解決辦法: 需要換到C盤的C:UsersASUS.ssh目錄下,再右鍵Git Bash Here 輸入命令: ssh-keygen -t rsa -C \\\'

    2024年02月04日
    瀏覽(26)
  • Git報錯:git@github.com: Permission denied (publickey)

    輸入指令 ssh -T git@github.com 測試SSH鏈接,出現(xiàn)如下報錯: git@github.com: Permission denied (publickey,password,keyboard-interactive). git@github.com: Permission denied (publickey). git@github.com\\\'s password: ,但是即是你輸入的是正確的密碼,依舊提示 Permission denied, please try again. 。 在網(wǎng)上搜索相關(guān)解決方案,

    2024年02月02日
    瀏覽(28)
  • 【git】git@github.com: Permission denied (publickey).報錯問題

    【git】git@github.com: Permission denied (publickey).報錯問題

    本媛開發(fā),會經(jīng)常性用到gitee GitHub兩個庫 畢竟國內(nèi)項目轉(zhuǎn)戰(zhàn)倉到gitee, 但是國外原框架還是GitHub居多 于是就出現(xiàn)連接pull-push經(jīng)常性切換問題 這個報錯是因為本地兩個倉都有ssh公共私有密鑰導(dǎo)致的 2.1.1 是因為首次本地聯(lián)通沒有配置密鑰,或者配置錯誤? 如果是因為第一次配

    2024年02月11日
    瀏覽(23)
  • git報錯:Permission denied (publickey). fatal: Could not read from remote repository.

    git報錯:Permission denied (publickey). fatal: Could not read from remote repository.

    背景 :由于新?lián)Q了電腦,新裝了git,所以在用git拉取代碼的時候就出現(xiàn)了標(biāo)題一樣的錯誤 ternimal下出現(xiàn)下面錯誤: Permissiondenied (publickey). fatal:Could not read from remote repository. Pleasemake sure you have the correct access rights and the repository exists. 分析原因 : 原因是由于你在本地(或者服務(wù)

    2024年02月05日
    瀏覽(28)
  • 解決在linux上git clone 時報錯 git@gitee.com: Permission denied (publickey). Could not read from remote repo

    解決在linux上git clone 時報錯 git@gitee.com: Permission denied (publickey). Could not read from remote repo

    今天在gitee上看到一個比較感興趣的項目,于是就想下載下來研究研究,結(jié)果git clone 克隆的時候報錯了,報錯如下: git@gitee.com: Permission denied (publickey).fatal: Could not read from remote repository.Please make sure you have the correct access rights and the repository exists. Permission denied (publickey) 沒有權(quán)

    2024年02月11日
    瀏覽(29)
  • Git push異常:Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password) fatal: Could not read

    Git push異常:Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password) fatal: Could not read

    在使用新的gitlab倉庫遷移舊代碼時,當(dāng)push代碼,報了如下異常: Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password) .fatal: Could not read remote repository. 在git bash下 1.先清楚本地舊的賬號密碼: git config --global --unset credential.helper 2.重新設(shè)置用戶名稱和郵箱 git config --global user.nam

    2024年03月17日
    瀏覽(30)
  • Permission denied (publickey). fatal: Could not read from remote repository.

    Permission denied (publickey). fatal: Could not read from remote repository.

    將本地代碼推送到遠程分支報錯:Permission denied (publickey). fatal: Could not read from remote repository. 確保已經(jīng)添加了正確的 SSH 密鑰??梢允褂靡韵旅顧z查 SSH 密鑰是否已經(jīng)添加: 如果看到消息 “Hi [username]! You\\\'ve successfully authenticated, but GitHub does not provide shell access.” ,則表示已成

    2023年04月18日
    瀏覽(20)
  • 終極辦法!connect to host port 22: Connection timed out git@ssh.github.com: Permission denied (publickey

    終極辦法!connect to host port 22: Connection timed out git@ssh.github.com: Permission denied (publickey

    過了個周末git突然用不了了,在拉代碼的時候突然報錯連接超時,又報錯說沒有權(quán)限,這就很煩了 在百度了很久以后嘗試了各種辦法,重新生成pub_key,重裝git等等都沒能解決,最后詢問了公司大佬,困擾了一個上午的問題終于解決了 先說說百度上的解決辦法: 使用命令 s

    2024年02月04日
    瀏覽(19)

覺得文章有用就打賞一下文章作者

支付寶掃一掃打賞

博客贊助

微信掃一掃打賞

請作者喝杯咖啡吧~博客贊助

支付寶掃一掃領(lǐng)取紅包,優(yōu)惠每天領(lǐng)

二維碼1

領(lǐng)取紅包

二維碼2

領(lǐng)紅包