Xcode 4中的Git提交信息在哪里设置? [英] Where is the Git commit info set in Xcode 4?

查看:198
本文介绍了Xcode 4中的Git提交信息在哪里设置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

请注意,这不是我面对的问题,我对这里发生的事情更感兴趣,因为这对我来说没有多大意义。



信息在哪里显示?





(您回复说),我曾用过我的联络卡。我可能应该指出,最初,使用中的提交作者姓名是我的本地用户名,并且没有照片。



点击照片显示一个popover我可以填写关于我自己的字段数量,例如名字,姓氏和一些联系信息。有一个选择卡... 按钮,我用它来附上我的卡。



所以它似乎像Xcode将我的联系人卡片附加到我的提交信息中,但事实证明,Xcode将它用于自己的显示目的,而不是将其绑定到我的Git作者信息。另外,正如评论中所提到的,我无法在任何Git配置文件中找到信息,此外我还没有使用GitHub(提示建议,链接和证明其令人敬畏)。



哦,我刚才检查过...更改我的联系人卡片中的一个字段会导致更改反映在Xcode中,反之亦然。


Note that this isn't a problem I face, I'm more interested in what is going on here, because this just doesn't make (much) sense to me.

Where is the info shown below set?

According to Daniel, when he runs a git log, the committer is shown as Daniel@daniel-macosx.local, which is his username on his Mac followed by his Mac's network hostname, so it isn't getting the Name and Icon from Gravatar or a similar service.

The photo shown is his user photo on his Mac.

Is it possible/where can a user set the committer info?

If it is possible to be set, should it be set in the global/project .gitconfig file, or somewhere else?

解决方案

Where is the info shown below set?

Actually, I think the answer was staring right at you all along... I'm fairly certain that all this info really is coming from my contact card, and is stored and used by Xcode independently of the version control system. In fact, I mentioned in an earlier tweet (which you replied to) that I'd used my contact card. I probably should have pointed out that, initially, the commit author name in use was my local username and there was no photo.

Clicking on the photo reveals a popover with a number of fields I can fill in about myself, like first name, last name, and some contact information. There's a Choose Card... button, which I used to attach my card.

So it does seem like Xcode attaches my contact card to my commit info, but it turns out that Xcode uses it for its own display purposes rather than tying it to my Git author info. Plus, as mentioned in the comments, I can't find the info in any of my Git config files, and furthermore I don't use GitHub yet (cue recommendations, links and testimonials as to its awesomeness).

Oh and I just checked... changing one of the fields in my contact card causes the change to be reflected in Xcode, and vice versa.

这篇关于Xcode 4中的Git提交信息在哪里设置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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