Create a new code project

You can quickly use Visual Studio with Git to create a new code project under local version control on your dev machine.

Create the code project

  1. If you haven't already, install Visual Studio 2013.

  2. In Visual Studio, create a project (Keyboard: Ctrl + Shift + N).

    New Project link on Start Page
  3. Choose a template and add the new code project to version control. We suggest that you put your new project in c:\Users\YourName\Source\Repos\

    New Project dialog box with 'Add to source control' selected
  4. When prompted, select Git.

    Choose source control dialog box with Git selected

    Your code project is created in your new local Git repository.

    Output window confirms that the new Git repository was created

Commit the code project

Before you begin coding, commit the new code project files in your local repository.

  1. View the changes (Keyboard: Ctrl + 0, G).
    Changes icon on the Home page 
  2. If you haven't entered your name and email address yet, you must do this first. These will be associated with your commits.
  3. Changes page prompting you to configure your user name and email address
  4. Now you can enter a comment, and commit your changes.

    Committing new files from the Changes page

    Your changes have been committed locally.

    Changes page confirms commit was successfully created

Try this next


Q:Can I get started with Git from a remote repository?

A:Yes. You can clone a remote repository to your dev machine.

Q:Can I use Git command-prompt tools?

A:Yes. Use Git from the command prompt.