为了账号安全,请及时绑定邮箱和手机立即绑定

无法在 mvn 发布时将文件提交到 github:spring boot 中的准备

无法在 mvn 发布时将文件提交到 github:spring boot 中的准备

喵喵时光机 2022-05-12 15:01:59
请指导我在执行 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] git@github.com: 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)。


查看完整回答
反对 回复 2022-05-12
  • 1 回答
  • 0 关注
  • 118 浏览

添加回答

举报

0/150
提交
取消
微信客服

购课补贴
联系客服咨询优惠详情

帮助反馈 APP下载

慕课网APP
您的移动学习伙伴

公众号

扫描二维码
关注慕课网微信公众号