Create branch and checkout in single command

    By: Thad Mertz
    3 years ago
    Category: GitViews: 20

    Here is the command

    git checkout -b local
    
    //here we are creating local branch and checking it out in sigle command
    

    In case you want to switch between branches just use checkout command

    git checkout master   // to get into master branch
    
    git checkout local    // to get into local branch again