[英]Problems with Editor when i do git commit
In my message for commit, I'm trying to use the guidelines: 在我的提交消息中,我正在尝试使用指南:
1º Line - summary with <80char 1º线 - 总结<80char
2º Line - space 2º线 - 空间
3º Line - The body message start here 3º线 - 身体信息从这里开始
In console, I'm doing this: 在控制台中,我这样做:
git commit git commit
then the editor opens and i write my message that i want to following the guidelines I save and then close the editor. 然后编辑器打开,我写了一条消息,我想遵循我保存的指导方针,然后关闭编辑器。
i return the console and it give me the error: 我返回控制台,它给我错误:
error: There was a problem with the editor '"C:/Program Files (x86)/GitExtensions/GitExtensions.exe" fileeditor'.
Please supply the message using either -m or -F option.
From what you are saying i can assume that you are using git extension on windows, i think that your issue is related to a bad configuration, configure the default text editor in the configuration pane of git extension . 从你的说法我可以假设你在Windows上使用git扩展,我认为你的问题与错误的配置有关,在git扩展的配置窗格中配置默认文本编辑器。
Otherwise you can commit without having the editor prompted each time in this way : 否则,您可以在不通过这种方式每次提示编辑器的情况下提交:
git commit -m "Your commit message"
If you want to have a multiline message you can break the line with a backslash : 如果你想要一个多行消息,你可以用反斜杠打破这一行:
git commit -m "1º Line - summary with <80char \
2º Line - space \
3º Line - The body message start here"
I suspect this is because your text editor does not exit with status code 0 (indicating success, and no error). 我怀疑这是因为你的文本编辑器没有退出状态代码0(表示成功,没有错误)。 What text editor are you using and did you quit the text editor cleanly?
你正在使用什么文本编辑器,你干净地退出了文本编辑器?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.