问题
I've tried typing in svn commit
and it will bring up a screen with the list of files being added/changed/etc. as well as a place to enter in a message, but pressing enter will add a newline to the message, not initiate the commit.
Is there a hotkey or some key combination to initiate the commit (it looks like there's some sort of emacs-ish like console at the bottom)? This is on a linux system.
回答1:
It will open your default editor; if you quit the editor, no log message will be saved; thus, the key combination to use depends on your editor. For Emacs, the sequence is Ctrl+X, Ctrl+C. If you want to commit a multi-line log message from a file, there is a -F
option to svn commit
to do that.
回答2:
Why do you not want to include a message? But you could just do svn commit -m ''
and submit a blank mesage.
回答3:
You need to save your commit message before exiting the editor. How you do this of course depends on the editor.
To change the default editor that svn uses you can set either the EDITOR
or SVN_EDITOR
environment variables. How this is done depends on what OS you use.
As an example, in linux you could add the following to your ~/.bash_profile:
export EDITOR=pico
For more information on choosing the external editor look here: Using External Editors.
来源:https://stackoverflow.com/questions/5150172/svn-commit-without-m