How to use multiple Git accounts in one machine

2022. 1. 28. 01:05Dev Tools/Git

Introduction

나의 2015년형 맥북 프로가 스티브잡스형 곁으로 떠날 때가 되어서, 요즘엔 개인적인 공부를 할 때도 가끔 회사 랩탑을 사용하고 있다. 그런

데 깃헙에 커밋을 하면 다른 계정이라서, 커밋기록이 남지 않아서 한 개 머신에서 여러개 깃 계정을 설정해서 사용하는 법을 검색해 보았다.

 

자세한 방법은 나중에 업데이트 하도록 하고, 우선은 링크만 공유해두자..

 

 

 

How to Git clone

//git clone using personal account
git clone git@github.com-personal_id:githubAccount/repository.git

//git clone using work account
git clone git@github.com-work_id:githubAccount/repository.git

 

How to git configure

We need to git configure at local to avoid git conflict.

git config --local user.name "Your Name"
git config --local user.email "Your Email"

 

 

Link:  

https://cursos.alura.com.br/forum/topico-fatal-local-can-only-be-used-inside-a-git-repository-184614

 

fatal: --local can only be used inside a git repository | Fórum Alura

Ao tentar mostrar para o git quem eu sou apresenta o seguinte erro:<br /><br />marcospatton@DESKTOP-6KIS69S MINGW64 ~<br />$ git config --local user.name marcospatton<br />fatal: --local can only be

cursos.alura.com.br

https://www.hostinger.com/tutorials/how-to-install-and-use-nano-text-editor

 

How to Install and Use Nano Text Editor: A Beginner's Tutorial

Nano is a great text editor for Linux. Follow this tutorial to learn how to install and use Nano text editor to boost your workflow.

www.hostinger.ph

https://gist.github.com/Jonalogy/54091c98946cfe4f8cdab2bea79430f9

 

Handling Multiple Github Accounts on MacOS

Handling Multiple Github Accounts on MacOS. GitHub Gist: instantly share code, notes, and snippets.

gist.github.com

https://1ilsang.dev/2020-02-30/devtip/github-multi-auth

 

GitHub 여러 계정을 한 컴터에서 사용하기 - 1ilsang

Developer who will be a Legend

1ilsang.dev

Generating a new SSH key and adding it to the ssh-agent - GitHub Docs

 

Generating a new SSH key and adding it to the ssh-agent - GitHub Docs

About SSH key generation If you don't already have an SSH key, you must generate a new SSH key to use for authentication. If you're unsure whether you already have an SSH key, you can check for existing keys. For more information, see "Checking for existin

docs.github.com