You may wish to set your personal email address for personal and open source repositories, and your professional email address for work-related repositories. One important exception is to override the author email address. Typically, you’ll only need to configure a Git installation the first time you start working on a new development machine, and for virtually all cases, you'll want to use the -global flag. ![]() The most common use case for bare repo is to create a remote central Git repositoryĪll configuration options are stored in plaintext files, so the git config command is really just a convenient command-line interface. If you prefer to host your own remote repo, you'll need to set up a "Bare Repository." Both git init and git clone accept a -bare argument. We discuss this process in the Configuration & Set Up guide below. ![]() Once you have created a remote repo with your service of choice you will need to update your local repo with a mapping. The service will provide a Git URL that you can then add to your local Git repository and git push to the hosted repo. A common pattern when initializing a new repo is to go to a hosted Git service like Bitbucket and create a repo there. If you used git init to make a fresh repo, you'll have no remote repo to push changes to. ![]() This means that once you make changes to a file and commit them, you can git push those changes to the remote repository. git clone will automatically configure your repo with a remote pointed to the Git URL you cloned it from. If you used git clone in the previous "Initializing a new Repository" section to set up your local repository, your repository is already configured for remote collaboration.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |