Resources
- http://mariusbancila.ro/blog/2013/01/31/visual-studio-2012-and-git/
- http://blogs.msdn.com/b/visualstudioalm/archive/2013/02/06/set-up-connect-and-publish-using-visual-studio-with-git.aspx
General Step from the guides above
- Install Git Tools from Microsoft
- Create your project in VS, and be sure to select the "Create Git Repo" option
- Right-click your project in the Solution Explorer, and "Add to Version Contol"
- Do an initial commit to your local git Repo
- In Team Explorer, click the drop-down and goto "Changes"
- Enter in a summary
- Click Commit
- Sync (in Team Explorer)
- From the drop-down click "Unsynced Commits"
- Drop in your Github (*.git) location - be sure to include the .git!
- Sync
Adding a branch to Github (from Visual Studio 2012)
- Create a local branch (Team Explorer --> Home --> Branches --> New Branch)
- Right-click the new branch under "Unpublished Branches" --> Publish Branch
Tip: If you got the "Branch master does not exist error", you can check out the solution in Resource #2. I have an *unconfirmed* suspicion that leaving out the (.git) extension in step #5 above will cause this error, as I recreated the project, adding the (.git) extension instead, and I can now commit to Master.
Tip: "Commit" is local, and "Sync" is Github (or remote). If you are working on multiple branches, don't forget to switch to the correct branch when making your edits.
Tip: "Commit" is local, and "Sync" is Github (or remote). If you are working on multiple branches, don't forget to switch to the correct branch when making your edits.
No comments:
Post a Comment