&引用;“认证失败”;maven scm提供程序jgit在发布期间出错:准备

&引用;“认证失败”;maven scm提供程序jgit在发布期间出错:准备,maven,maven-release-plugin,jgit,maven-scm,Maven,Maven Release Plugin,Jgit,Maven Scm,我在一台没有安装git命令行的windows计算机上。我已经安装了GitExtensions和EGit,这对我来说已经足够了(直到现在) 现在,我想按照以下指南对BinTray执行maven发布: 运行: mvn -Prelease release:prepare 生成此输出: [INFO] ------------------------------------------------------------------------ [INFO] Building xxxxx 1.0.0-

我在一台没有安装git命令行的windows计算机上。我已经安装了GitExtensions和EGit,这对我来说已经足够了(直到现在)

现在,我想按照以下指南对BinTray执行maven发布:

运行:

mvn -Prelease release:prepare
生成此输出:

[INFO] ------------------------------------------------------------------------
[INFO] Building xxxxx 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-release-plugin:2.4.1:prepare (default-cli) @ xxxxx ---
[INFO] Resuming release from phase 'scm-commit-release'
[INFO] Checking in modified POMs...
[INFO] Executing: cmd.exe /X /C "git add -- pom.xml"
[INFO] Working directory: C:\Users\jbr\git\yyyyyyyyyyyyyyy
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.770 s
[INFO] Finished at: 2015-09-12T20:17:24+02:00
[INFO] Final Memory: 20M/989M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.4.1:prepare (default-cli) on project xxxxx: Unable to commit files
[ERROR] Provider message:
[ERROR] The git-add command failed.
[ERROR] Command output:
[ERROR] 'git' is not recognized as an internal or external command,
[ERROR] operable program or batch file.
绝对公平,我从不使用windows shell中的git命令,也从不设置pageant.exe。(详情请参阅)

我的第二个想法是使用,不依赖于
git
命令行

现在输出为:

[INFO] ------------------------------------------------------------------------
[INFO] Building xxxxx 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-release-plugin:2.4.1:prepare (default-cli) @ xxxxx ---
[INFO] Change the default 'git' provider implementation to 'jgit'.
[INFO] Resuming release from phase 'scm-commit-release'
[INFO] Checking in modified POMs...
[INFO] push changes to remote... refs/heads/master:refs/heads/master
[INFO] fetch url: git@github.com:jmini/yyyyyyyyyyyyyyy.git
[INFO] push url: git@github.com:jmini/yyyyyyyyyyyyyyy.git
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.4.1:prepare (default-cli) on project xxxxx: An error is occurred in the checkin process: Exception while executing SCM command. JGit checkin failure! git@github.com:jmini/yyyyyyyyyyyyyyy.git: Auth fail -> [Help 1] 
好多了,但还是不走运

我的猜测是私钥和密码短语没有加载。我应该如何配置它们


建议对于某些SCM提供程序,可以在
settings.xml
部分中指定凭据。存储库的域名应用作
。 根据
scm:git的最后一条评论:ssh://git@bitbucket.org/{account}/{project}
用于
中,此条目在
设置.xml中工作:

<server>
  <id>bitbucket.org</id>
  <privateKey>/c/Users/neil.hunt/.ssh/id_rsa</privateKey>
</server>

bitbucket.org
/c/Users/neil.hunt/.ssh/id\u rsa
JGit SCM提供程序是否支持此构造


在搜索“Auth failed”错误时,我发现了这个相关的问题(纯JGit,没有maven插件):


为什么要使用旧版本的。我看不出您是否使用最新版本的maven scm provider?没有理由(从某些网站复制粘贴)。我已将
maven release plugin
更新为
2.5.2
,并使用
maven scm提供程序jgit
版本
1.9.4
。您是否尝试在cygwin中的普通windows命令行上运行您的版本?