How do I correctly install dulwich to get hg-git working on Windows?

后端 未结 10 2151
执念已碎
执念已碎 2021-01-31 01:35

I\'m trying to use the hg-git Mercurial extension on Windows (Windows 7 64-bit, to be specific). I have Mercurial and Git installed. I have Python 2.5 (32-bit) installed.

<
10条回答
  •  心在旅途
    2021-01-31 02:07

    I found a simpler solution at http://candidcode.com/2010/01/12/a-guide-to-converting-from-mercurial-hg-to-git-on-a-windows-client/

    And then I found a yet simpler solution myself:

    To use the hg-git Mercurial extension on Windows:

    1. install the official Mercurial binaries
    2. put dulwich folder from dulwich sources and hggit folder from hg-git sources to the root of library.zip in Mercurial installation folder
    3. add the following to %USERPROFILE%\Mercurial.ini:

    [extensions]
    hgext.bookmarks=
    hggit=
    

    To have SSH support you need plink.exe from PuTTY family. After that you should add the following to Mercurial.ini:

    [ui]
    username = John Doe 
    ssh=d:/home/lib/dll/plink.exe -i "d:/home2/ssh-private-key.ppk"
    

    When connecting to a SSH server for the first time, you should start putty.exe and try to connect using it. It will add the server key fingerprint to the registry. Otherwise plink will ask you to accept the fingerprint but it doesn't accept any input.

    You can use puttygen.exe to generate private keys. Either use keys without a passphrase or use Pageant.exe ssh authentication agent.

提交回复
热议问题