PhpStorm 默认 git 作者
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/26411075/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
PhpStorm default git author
提问by Simon Schneider
In PhpStorm I am having difficulty setting the default git author in the project settings:
在 PhpStorm 中,我很难在项目设置中设置默认的 git 作者:
I used the "Action finder" and searched through the settings, but I have not found this option.
我使用了“Action finder”并搜索了设置,但我没有找到这个选项。
Does anyone know where I can change this value, so I don't have to change it on every commit?
有谁知道我可以在哪里更改这个值,所以我不必在每次提交时都更改它?
回答by Simon Schneider
Thanks to the information given by Andrew I was able to find a solution:
感谢 Andrew 提供的信息,我找到了解决方案:
Go to your project folder \ .git \ config and add the lines below:
转到您的项目文件夹 \ .git \ config 并添加以下行:
[user]
name = Your Name
email = [email protected]
I hope this was helpful for other PhpStorm and git users.
我希望这对其他 PhpStorm 和 git 用户有帮助。
回答by Andrew C
No clue on PhpStorm, but you should be able to do git config user.name "Your Name"
and git config user.email "Your email"
from a command line inside the repo and perhaps achieve the results you want.
没有关于 PhpStorm 的线索,但您应该能够从 repo 内的命令行执行git config user.name "Your Name"
和操作git config user.email "Your email"
,并可能达到您想要的结果。