Skip to content

nrsiward/branching_tut

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

Branching tutorial

Get your own copy of the repository

  1. In GitHub, fork nrsiward/branching_tut to your account
  2. Clone branching_tut from your account to your local disk

Implementing a new feature

  1. Create branch feature1 (to implement a new feature)
  2. Change line 2 in file1.txt

Making an urgent bug fix at an inconvenient time

  1. Stash
  2. Change back to branch master (to make a bug fix before the feature is done)
  3. Edit line 3 and line 4 in file1.txt
  4. Stage and commit

Finishing the new feature

  1. Change to branch feature1
  2. Pop the stash
  3. Change line 4 in file1.txt (to finish implementing the feature)
  4. Stage & commit

Merge the new feature

  1. Change to branch master
  2. Merge branch feature1
  3. Resolve conflicts

Share with others

  1. Push

Clean up the uneeded branch

  1. Delete local branch feature1
  2. Push the branch deletion

About

Repo for use in a tutorial on Git branching

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published