I am using the following to edit the current command line in Sublime Text 2 (using a working subl
alias)
.zshrc
set -o vi
EDITOR='subl'; export EDITOR
bindkey -M vicmd v edit-command-line
This opens up sublime, but the window is blank. If I set the editor back to Vim, I am able to open a new vim buffer with the current command line in it. fc
works just fine.
$EDITOR
is meant to contain the path to an editor or more exactly an editor command, something that you canexecp
(to be used by anything needing to start an editor, not onlyfc
) not a shell alias.EDITOR
should besubl -w
, not sure if that will help... And BTW, there's a sublimetext2 tag over at StackOverflow that might be of use next time you have a question - I know more users/plugin programmers monitor it theresubl -w
seems to have sorted it. Thanks Matt. If you want to post that as an answer I will accept it : )