3
votes

My company has just begun using BitBucket with Mercurial for version control and I am having a heck of a time integrating it locally with Visual Studio 2010. I can easily create a folder on my local system and clone the BitBucket repository using TortoiseHg and it brings down all the files appropriately. However, when I try to create a Visual Studio project in the same folder, it insists on creating it's own sub-folder for the project files, leaving my version controlled source files out of the project. When I try to do it the opposite way, creating my solution in Visual Studio first, TortoiseHg will not let me clone my repository into the same directory, saying that it needs a new folder. All of my google-foo seems to be coming up fruitless.

Anyone have a clean way of setting up a cloned repository from which to work locally in Visual Studio using Mercurial and BitBucket?

1

1 Answers

2
votes

You can

  1. Create your Visual Studio project.

  2. Right-click the project folder and choose TortoiseHg -> Create Repostory Here.

  3. Add and commit files in TortoiseHg.

  4. Push the repository into a new empty repository on Bitbucket. To push, you use the synchronize view and add a new path to the repository. Name the path default and it will become the default push and pull path.

The important point is that you can always push into an empty repository. This is how you copy a repository you've worked on locally to Bitbucket: create a new empty repository online and push to it.