开发者

hg push with credentials for HTTP server

I have a HTTP server with some Mercurial repositories; in which I handle digest authentication开发者_Python百科, and I found myself pushing changes to the server too often, so, I wanna know If is there any way to send the credentials (user and password) along with the hg push command?

Thanks


Please use the auth section in your hgrc file. That will let you write things like:

[auth]
bb.prefix = https://bitbucket.org/
bb.username = mg
bb.password = something


With http authentication, I use hg push https://user:password@url.com in hgrc file, not sure if it helps here.


TortoiseHg 0.9.3 is the first version to include the mercurial_keyring extension, and I'm quite happy with it. The previous link shows the required configuration to make it work.

Mercurial 1.4.3 doesn't include it, but I hope it's just a matter of time before it will be available as a part of the Mercurial packages.


There is a default password extension to automatically provide credentials. There's not much advantage to this beyond embedding the creds right in the url as Sejanus suggests. It's still plaintext, but does put your password into a separate file, the location of which you can control. Without this, the password is stored in the .hg folder in your workspace, so this might be preferable if the filesystem your workspace is on is shared.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜