Skip to content

Instantly share code, notes, and snippets.

@goodGid
Last active October 29, 2023 05:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save goodGid/9a6ebdae1acd890d6fe3d7f6263c86cb to your computer and use it in GitHub Desktop.
Save goodGid/9a6ebdae1acd890d6fe3d7f6263c86cb to your computer and use it in GitHub Desktop.
n개 이상 Git계정 사용
  • ~/.ssh/config
# goodgid
Host github.com
 HostName github.com
 User git
 AddKeysToAgent yes
 IgnoreUnknown UseKeychain
 # UseKeychain yes
 IdentityFile ~/.ssh/id_rsa_goodgid

# goodgid-fc account
Host github.com
 HostName github.com
 User git
 AddKeysToAgent yes
 IgnoreUnknown UseKeychain
 # UseKeychain yes
 IdentityFile ~/.ssh/id_rsa_fc

# goodgid-rich account
Host github-rich
 HostName github.com
 User goodgid-rich
 IdentityFile ~/.ssh/id_rsa_rich
@goodGid
Copy link
Author

goodGid commented Oct 29, 2023

Blog

  • /Users/goodgid/Desktop/goodgid/Blog

git config -e

[core]
        repositoryformatversion = 0
        filemode = true
        bare = false
        logallrefupdates = true
        ignorecase = true
        precomposeunicode = true
[remote "origin"]
        url = ssh://git@github.com/goodGid/goodGid.github.io.git
        fetch = +refs/heads/*:refs/remotes/origin/*
        pushurl = ssh://git@github.com/goodGid/goodGid.github.io.git
[user]
        name = goodGid
        email = hello.goodgid@gmail.com
[branch "kakaopay-qr"]
        remote = origin
        merge = refs/heads/kakaopay-qr
[branch "master"]
        remote = origin
        merge = refs/heads/master

git remote -v

origin	ssh://git@github.com/goodGid/goodGid.github.io.git (fetch)
origin	ssh://git@github.com/goodGid/goodGid.github.io.git (push)

@goodGid
Copy link
Author

goodGid commented Oct 29, 2023

Rich

  • /Users/goodgid/Desktop/goodGid/Rich

git config -e

[core]
        repositoryformatversion = 0
        filemode = true
        bare = false
        logallrefupdates = true
        ignorecase = true
        precomposeunicode = true
[submodule]
        active = .
[remote "origin"]
        url = git@github-rich:goodgid-rich/goodGid-rich.github.io.git
        fetch = +refs/heads/*:refs/remotes/origin/*
[branch "master"]
        remote = origin
        merge = refs/heads/master```

> git remote -v

- git remote set-url origin git@github-rich:goodgid-rich/goodGid-rich.github.io.git

origin git@github-rich:goodgid-rich/goodGid-rich.github.io.git (fetch)
origin git@github-rich:goodgid-rich/goodGid-rich.github.io.git (push)



> git clone

- git clone git@github-rich:goodgid-rich/goodGid-rich.github.io.git

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment