Git Branching and Merging with Example

helpmecoder
helpmecoder
76.6 هزار بار بازدید - 5 سال پیش - Git Branching and merging help
Git Branching and merging help us to have multiple parallel development without impacting/disturbing the main code repository or the current production deployed code.
Agenda for Today

1. Learn Branching with Example (Pictorial Representation)
2. What are branches
3. How to create branch  
4. How to checkout branch
5. How to merge branch to master

Branching and Merging Commands
---------------------------------------------------------

Command 1: Creating a Branch
git branch “branch name”

Command 2: Seeing all the Branches
git branch

Command 3: Moving to another branch
git checkout “branch name”

Command 4: Checking work done on a file into stage
Git add “files to be staged”

Command 5: Committing data into Git
Git commit –m “comment on the file changes”

Command 5: see the difference/changes between the branches
git diff master “new branch name”

Command 6: Merge new branch in master branch
git merge “branch name”

Command 7: Delete branch
git branch -d “branch name”


Website – https://helpmecoder.com

----------- Follow -----------
Facebook – Facebook: helpmecoder
Twitter – Twitter: HelpMeCoder
YouTube - helpmecoder

#git
#gitbranching
#gitmerging
#gitbranch
#gitmerge
#gitcheckout
#github
#gitpull
5 سال پیش در تاریخ 1398/02/19 منتشر شده است.
76,665 بـار بازدید شده
... بیشتر