2014-03-05 39 views
1

我在使用Mercurial keyring扩展与Windows Server 2008R2中的TortoiseHg(v2.11.1 64位)时遇到了一些无法解释的困难。无法在Windows中使用mercurial_keyring扩展,TortoiseHg和Kiln执行hg推送

扩展似乎已启用(mercurial_keyring条目存在于mercurial.ini以及repo hgrc文件中),并且我设置了默认的repo URL来传递我的用户帐户(例如'default=http://[email protected]/reponame/')。
我已经从命令提示符手动推送将我的密码存储在Windows凭据存储区中,该凭据存储区似乎正常工作 - 后续从命令提示符推入时不请求身份验证。我还可以在Windows Credential Store中看到'Mercurial'条目。 我已经确认我的PATH环境变量指向只有到由TortoiseHg安装的hg.exe实例。 最后,我在Jenkins中创建了一个工作,试图执行一次提交并推送相同的存储库,我做了我的测试,以存储我的凭据。这项工作,但是,失败,出现以下消息:

16:33:00 c:\_servers\Jenkins>hg push --debug 

16:33:12 pushing to http://<username>@<my-host-name>/kiln/Code/<repo path> 
16:33:12 using http://<my-host-name>/kiln/Code/<repo path> 
16:33:12 http auth: user <username>, password not set 
16:33:12 sending capabilities command 
16:33:12 query 1; heads 
16:33:12 sending batch command 
16:33:12 searching for changes 
16:33:12 all remote heads known locally 
16:33:12 sending branchmap command 
16:33:12 sending branchmap command 
16:33:12 preparing listkeys for "bookmarks" 
16:33:12 sending listkeys command 
16:33:12 2 changesets found 
16:33:12 list of changesets: 
16:33:12 e7131cb8af1d3e64e678861c687d76025d3c639f 
16:33:12 7bc85ba011df5c423244e3222efd7ebf6b5f0dd6 
16:33:12 bundling: 1/2 changesets (50.00%) 
16:33:12 bundling: 2/2 changesets (100.00%) 
16:33:12 bundling: 1/2 manifests (50.00%) 
16:33:12 bundling: 2/2 manifests (100.00%) 
16:33:12 bundling: .hgignore 1/2 files (50.00%) 
16:33:12 bundling: <mutated file list> 2/2 files (100.00%) 
16:33:12 sending unbundle command 
16:33:12 sending 685 bytes 
16:33:12 sending: 0 kb 
16:33:12 sending: 0 kb 
16:33:12 [HgKeyring] Keyring URL: http://<my-host-name>/kiln/Code/<repo path> 
16:33:12 [HgKeyring] Looking for password for user <username> and url `http://<my-host-name>/kiln/Code/<repo path>` 
16:33:12 [HgKeyring] **Password not present in the keyring** 
16:33:12 abort: mercurial_keyring: http authorization required but program used in non-interactive mode 

我不知道我做错了,或者这仅仅是不是一个可行的配置,但我一定会感激的任何建议。感谢您的考虑。

回答

0

您需要手动推送作为Jenkins在下运行的用户帐户,以便将密码存储在Windows用户的密钥环中。