Skip to content

Latest commit

 

History

History
70 lines (47 loc) · 1.1 KB

04-Practice-Test-Merging-Branches.md

File metadata and controls

70 lines (47 loc) · 1.1 KB

Practice Test - Merging Branches

Solutions to practice test - merging branches

  • Run cd /home/sarah/story-blog; git checkout master and then list the files ls

    $ cd /home/sarah/story-blog
    $ git checkout master
    $ ls
    
  • Run cd /home/sarah/story-blog and then list the files ls

    $ cd /home/sarah/story-blog
    $ ls
    
  • Run git branch

    $ git branch
    
  • Run git log

    $ git checkout master
    $ git log
    $ git checkout story/frogs-and-on
    $ git log
    
  • Run git merge story/frogs-and-ox. Check git log now and it should show commit message as Merge branch 'story/frogs-and-ox' into master

    $ git checkout master
    $ git merge story/frogs-and-ox
    $ git log
    
  • List the files in the master branch and make sure both the stories are visible.

    $ ls