Where are my git branches?

I was working on my work computer the other day and set up a new branch in github. I made a local and remote branch.

Today I am working on my laptop at home and I don’t see my branch that I made when I run “git branch”.

  • Upload new project into github repo?
  • Wiki - File versioning
  • Delete all tags from a Git repository
  • Creating a git alias to append to .gitignore
  • Installing Python package pathos from git
  • How to get youngest revision in a Git repository
  • How do I get access to this branch?

  • List commits not touching specific paths
  • Publishing a gitflow feature branch to gerrit
  • Subtle difference with git pull --rebase and git rebase?
  • git svn workflow - feature branches and merge
  • workflow for multiple related feature branches
  • Change Git repository directory location.
  • 3 Solutions collect form web for “Where are my git branches?”

    assuming you have this branch in your local repository, you can use git checkout <branchname> to checkout a branch

    If this branch is on the github repository but not in your local repository, you may want to git remote update before git checkout <branchname> and git pull to fetch changes

    What seems to have happened here, is that your local cache of the remote state is outdated. Before you can access these new branches you will need to refresh your local copy of the repository’s state.

    You can do this with:

    1. git remote update (see the earlier answer by Michael Ira Krufky)
    2. git fetch [remotename]

    Additionally when you run git pull this automatically includes a git fetch so that would also update your local copy

    try git branch -a to show all the branches.

    Git Baby is a git and github fan, let's start git clone.