svn ci multiline message log/text file with log message

↘锁芯ラ 提交于 2019-12-24 04:52:19

问题


I have this problem when I do

svn ci -m "Message text multiline" dir/

I want the log message to look like:

fixed:
-bug 1
-bug 2
-bug 3

Instead I get:

fixed: -bug 1-bug 2- bug 3

This is caused because I can't insert a newline (\n\r) in the log message.

I use putty for the SVN. I searched a little bit and I saw that for the echo command there is a solution:

echo -e "new\n\rline"

will output:

new
line

Also I saw there is a way instead of -m "message" to specify a text.txt file where I can put the log already formatted, but I didn't find an example.

Can somebody help me fix this issue, please?


回答1:


Use the -F option to specify the log message file instead of -m:

svn ci -F logmessage.txt dir/

See another example of using it in the documentation.




回答2:


I found out that you can add new line even with svn ci -m, it will work only if you wrote down only one coma : [good] - svn ci -m "press enter then close coma.

[bad] - svn ci -m "" dir/ (and then add the text with new lines)



来源:https://stackoverflow.com/questions/26846207/svn-ci-multiline-message-log-text-file-with-log-message

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!