Git Commands
Git Commands
Git Commands:-
• git clone :- Used to clone a repository from github to local.( will be used one time to clone the code)
• git branch “branchname” :- used to create a new working branch from main branch.
• git checkout branchname :- to checkout the working branch to be worked on.
• git status :- to check the status of the branch will show all the changes done by us.
• git add . :- to add all the changes to the working branch.
• git commit –m” message to commit” :- It is use to commit the changes to the working branch locally.
• git push origin branchname :- to push the working branch to the main branch in git hub.
• git pull origin branchname:- to pull the updated code from git repository.