GIT HUB

List of useful Github Commands : 

Github is a distributed version of repositories for open source developers. list of few commands and you can use frequently on github( in git bash) is shown below :

for any kind of help on github about command line 

git help   

basic configurations on github like your name and email. 

git config

your user name on git. 

git config –global user.name “Prakash nidhi verma”

for mail 

git config –global user.email xyz12@gmail.com

for color 

git config –global color.ui true


mkdir store 
cd store 
git status
git add Readme.txt 


GIT HUB


for status and add file and text

git log 
git add 
git add --all 
git add *.txt 
git add docs/*.txt 
git add docs/ 
git add “*.txt” 
git diff 
git reset head license 
git checkout –license 
git commit -a -m “Readme.md” 

commit for local server 

git remote add origin https://github.com/pnidhi123/MyAlgorithms.git

local repository for a particular git address. 

git remote add <address>

To remove a remote from our local repository. 

git remove rm

To create a new branch named as Testing. 

git branch Testing

for current branch 

git branch

To see directories and files in the current directory.

ls

To merge Testing branch with master branch. 

git merge Testing

To delete Testing branch. 

git branch -d Testing 

To create a new branch admin and set it as current branch. 

git checkout -b admin

To look at all the remote branches. 

git branch -r

To see the list of available tags.

git tag

To push the tags to remote repository.

git push –tags

To fetch down any changes from global repository to current repository 

git fetch
git rebase

                                  GIT HUB

Leave Comment