請指導我在執行 mvn release:prepare 時如何繼續進行,如果需要,請告訴我如何在我的項目中添加 ssh 密鑰。我嘗試了許多解決方案,但沒有一個有效,因為它每次都顯示相同的錯誤,這是我基于模塊化方法的項目,我使用的 IDE 是 IntelliJ。[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release- plugin:2.5.3:prepare (default-cli) on project vj-pet-clinic: Unable to commit files[ERROR] Provider message:[ERROR] The git-push command failed.[ERROR] Command output:[ERROR] [email protected]: Permission denied (publickey).[ERROR] fatal: Could not read from remote repository.[ERROR] Please make sure you have the correct access rights[ERROR] and the repository exists.[ERROR][ERROR] -> [Help 1][ERROR][ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.[ERROR] Re-run Maven using the -X switch to enable full debug logging.[ERROR][ERROR] For more information about the errors and possible solutions, please read the following articles:[ERROR] [Help 1]http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
1 回答

慕碼人2483693
TA貢獻1860條經驗 獲得超9個贊
您可以使用 HTTPS 而不是 SSH 來避免密鑰交換。這是一個例子:
<scm>
<url>https://github.com/(username)/(repo)</url>
<connection>scm:git:https://github.com/(username)/(repo).git</connection>
</scm>
(username)并相應地替換(repo)。
添加回答
舉報
0/150
提交
取消