jez / vim-superman

Read Unix man pages faster than a speeding bullet!
http://blog.jez.io/2014/12/20/vim-as-a-man-page-viewer/
MIT License
190 stars 20 forks source link

allow overriding editor name #17

Closed timfeirg closed 6 years ago

timfeirg commented 6 years ago

vim-superman is such an awesome plugin ... truly revolutionary.

however, neovim name their executable nvim, so I thought it'd be nice if one can configure which vim executable to use in vim-superman.

jez commented 6 years ago

Ah, good idea!

How do you feel about just re-using the EDITOR variable, so that people don't have to set some other variable?

This way it's more likely to work out of the box.

timfeirg commented 6 years ago

I guess it won't work if $EDITOR is nano or emacs ... or anything that isn't vim or neovim, I mean in general vim-compatible, and this $EDITOR must have installed vim-superman, and interpret -c "SuperMan $*" correctly.

But yeah, using $EDITOR is the more sensible option here, might wanna add some kind of heads-up (or documentation) saying that $EDITOR must be vim or neovim.

The worst case is that people might install this plugin using vim, but use other program as their $EDITOR. But this makes no sense, I wouldn't worry about this.

If we decided to use $EDITOR, I'll try to add some docs, but I fear I'm not eloquent enough to do that.

jez commented 6 years ago

But this makes no sense, I wouldn't worry about this.

Yep, I agree. I think anyone who wants to read man pages in Vim probably has EDITOR set to Vim.

Thanks for the PR!