Skip to content

Checking out a branch #291

Closed
Closed

Description

@amlwwalker

How do I checkout a branch?
I can open a repo, create a branch, stage changes, commit changes, but what I need to do is checkout an existing branch.
How do you do that?

Activity

  1. carlosmn commented on Feb 15, 2016

    @carlosmn
    Member

    You can use Repository.CheckoutTree() to checkout the files. If by "checkout a branch" you mean switch to that branch, you will also need to update HEAD, e.g. with Repository.SetHead()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions