Skip to content

Latest commit

 

History

History
58 lines (36 loc) · 2.43 KB

remote_repo.md

File metadata and controls

58 lines (36 loc) · 2.43 KB

GUIDE TO CREATE A REMOTE REPOSITORY

A remote in Git is a common repository that all team members use to exchange their changes. In most cases, such a remote repository is stored on a code hosting service like GitHub or on an internal server.In contrast to a local repository, a remote does not provide a file tree of the project's current state but only consists of the .git versioning data.

Now , to setup a remote repository , follow the given instructions :-

To add a new remote, use the git remote add command on the terminal, in the directory your repository is stored at.

The git remote add command takes two arguments:

A remote name, for example :

origin

A remote URL

For example:

Screenshot 2020-10-20 at 9 39 42 AM

To set a new remote type :

$ git remote -v
For example :-

Screenshot 2020-10-20 at 9 42 31 AM

Verify new remote

origin https://github.com/user/repo.git (fetch)

origin https://github.com/user/repo.git (push)

For example :-

Screenshot 2020-10-20 at 9 43 55 AM

To check all your remote repositories type :

git remote
For example :-

Screenshot 2020-10-20 at 9 46 45 AM

After typing git remote , you should see the below

Screenshot 2020-10-20 at 9 48 37 AM

As you see , if you find your remote name in the list , you have successfully created a remote repository .
Hope , this helps you , all the best and happy coding