![]() Pick the correct pair for your repository accordingly. Git config user.email config user.name "Rahul Pandey" If it is still your old account's name, use command: git config -global user. you can type: git config -global user.name to check the name. ![]() git config user.email config user.name "Rahul Pandey" 1 If my guess is right, it is because your global name is still account A. Now for cloning the repo use the below command: git clone git clone now on, to ensure that our commits and pushes from each repository on the system uses the correct GitHub user - we will have to configure user.email and user.name in every repository freshly cloned or existing before. I am making a repository on my personal github account and naming it TestRepo Make a new project folder where you want to clone your repository and go to that directory from your terminal. We will clone a repository using one of the account we have added. Configure Git in your Workspace In your shell, add your user name: git config -global user.name 'yourusername' Add your email address: git config -global user. So we are done with our setups and now its time to see it in action. Configure Git in your workspace Make/check SSH credentials Update Online Github settings Step 1. Step 5 Cloning GitHub repositories using different accounts IdentityFile ~/.ssh/github-rahul-personal ![]() ![]() Now we need to add these lines to the file, each block corresponding to each account we created earlier. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |