Ssh git提交其他github电子邮件?
我建立了一个工作和个人github帐户。为了区分它们,我在~/.ssh中创建了一个配置文件:Ssh git提交其他github电子邮件?,ssh,Ssh,我建立了一个工作和个人github帐户。为了区分它们,我在~/.ssh中创建了一个配置文件: Host workusername.github.com HostName github.com PreferredAuthentications publickey IdentityFile ~/.ssh/id_rsa Host personalusername.github.com HostName github.com PreferredAuthentications publickey Use
Host workusername.github.com
HostName github.com
PreferredAuthentications publickey
IdentityFile ~/.ssh/id_rsa
Host personalusername.github.com
HostName github.com
PreferredAuthentications publickey
User personalusername
IdentityFile ~/.ssh/id_rsa_personalusername
我保存了配置并输入了
git config user.name“personalusername”
令我沮丧的是,我看起来像:
personalusername <workemail>
personalusername
git用户名与我在github.com设置中指定的用户名不关联。git config user.email personalemail。关闭终端并再次打开