Remote repository

Adding a remote repository

$ git remote add [repositoryname] [repositoryURL]
$ git remote add ajeshRepository

Commands with the remote repository are
$ git push [repositoryname] master    #master is default branch
#eg $ git push ajeshRepository master
$ git fetch [repositoryname]    
# eg $ git fetch ajeshRepository
$ git merge [repositoryname]/master    
#eg $ git merge ajeshRepository/master
$ git pull [repositoryname] master   
#eg $ git pull ajeshRepository master

Viewing all remote repository

$ git remote -v
ajeshRepository (fetch)
ajeshRepository (push)

Deleting remote repository

$ git remote remove ajeshRepository

You must login to comment

No comment yet

  • Online: 9
    Registered users: 7
    Unique visitors: 174
    Total hits: 491