Git提交作者信息 - 谁是基督徒S.? [英] Git commit author information - Who the heck is Christian S.?

查看:124
本文介绍了Git提交作者信息 - 谁是基督徒S.?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近开始使用git。我试图按照设置我的用户信息的指示,但是这样的事情似乎变得非常糟糕:

  [test @ h] git config --list 
user.name = **我的名字**
user.email = **我的电子邮件**
core.repositoryformatversion = 0
core.filemode = true
core.bare = false
core.logallrefupdates = true
remote.origin.fetch = + refs / heads / *:refs / remotes / origin / *
remote.origin。 url = ** URL **
branch.master.remote = origin
ranch.master.merge = refs / heads / master

到目前为止,这么好。我的名字&电子邮件地址似乎设置正确

  [test @ h] git add somefile 



我已经添加了一个文件,现在要提交它:

  [test @ h] git commit -mtest commit
[master 280efe4] test commit
作者:Christian S.< strcat @ ****。com>
1文件已更改,0插入(+),0删除( - )
创建模式100644 somefile

突然冒出来...... Christian S。



我忽略了什么?我不知道这个名字和电子邮件地址是从哪里来的。



编辑:删除个人信息

解决方案

好吧,所以我找到了解决方案,感谢pst。我正在开发一个系统范围为.zshrc文件的开发服务器。



显然,.zshrc文件的来源是: http://www.strcat.de/dotfiles/dot.zshexports



在此文件中,作者姓名和电子邮件地址是硬编码的:

  if [[-x`which git`]];然后
(($ {+ GIT_AUTHOR_EMAIL}))|| export GIT_AUTHOR_EMAIL =...
...


I recently started using git. I tried to follow the instructions of setting my user information, but soemthing seems to go horribly wrong:

[test@h] git config --list
user.name=**MY NAME**
user.email=**MY EMAIL**
core.repositoryformatversion=0
core.filemode=true
core.bare=false
core.logallrefupdates=true
remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*
remote.origin.url=** URL **
branch.master.remote=origin
ranch.master.merge=refs/heads/master

So far, so good. My name & email address seem to be set correctly

[test@h] git add somefile

I've added a file and now want to commit it:

[test@h] git commit -m "test commit"     
[master 280efe4] test commit
Author: Christian S. <strcat@****.com>
1 file changed, 0 insertions(+), 0 deletions(-)
create mode 100644 somefile

Suddenly out of nowhere... Christian S.

What have I overlooked? I have no Idea where this name and email address comes from. Is this some default value I forgot to override somewhere?

EDIT: Removed personal information

解决方案

Ok so I found the solution thanks to pst. I was working on a development server where a system wide .zshrc file is in place.

Apparently the source for the .zshrc file was: http://www.strcat.de/dotfiles/dot.zshexports

And within this file, the Author's name and Email address were hardcoded:

if [[ -x `which git` ]]; then
   (( ${+GIT_AUTHOR_EMAIL} )) || export GIT_AUTHOR_EMAIL = "..."
       ...

这篇关于Git提交作者信息 - 谁是基督徒S.?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆