Mercurial and SSH-2 DSA on Windows XP

After installing Mercurial and TortoiseHG on Windows XP I subscribed to the SCM Hosting provider and so far I am very pleased with their service. The subscription process was straight forward, the repository usable within minutes after subscribing and all of that for a very affordable price, I might add.

I had fun exploring Mercurial as a next generation distributed source code management system – until I hit that SSH wall, that is.  So here is a short description how to configure SSH on Windows XP:

  1. Download and install putty-0.60-installer.exe.
  2. Fire up the  PuTTY Key Generator, chose SSH2-DSA and fill in the form.
  3. Save the private key to a file.
  4. Copy the public key as it appears in the text area field (including the first line) to the server.
  5. Start up Pageant – if its running, an icon with a computer wearing a heat is visible in the system tray. Right-click on that icon and select “Add Key”.
  6. Tell Pageant where to find your private key.
  7. Append the follwoing line to the [ui] section of your .mercurial.ini file:
    ssh="/path/to/plink.exe" -ssh -i "/path/to/your/private/key"

Done! You should be able to clone and push to your server.

Leave a Reply

Your email address will not be published. Required fields are marked *