vim:nvim-man: Source vimrc and fix weird input
Remove `NORC` as settings like `smartcase` or my color scheme are things I do not want to miss and the startup time delta feels negligible. Fix a weird issue with presumably the line breaks and tabs in the command string that would make vim send key inputs when starting through `nvim-man`. This would lead to tmux switching panes and tmux-resurrect failing to recover panes with vim opened like this.
This commit is contained in:
@@ -401,13 +401,7 @@ nvim-man() {
|
|||||||
command man -w "$1" >/dev/null || return
|
command man -w "$1" >/dev/null || return
|
||||||
|
|
||||||
# $MANPAGER would do the trick too but lines would be hard-wrapped.
|
# $MANPAGER would do the trick too but lines would be hard-wrapped.
|
||||||
nvim -u NORC +"
|
nvim +"Man $1 | only | set scrolloff=999 | normal M"
|
||||||
runtime! plugin/man.vim |
|
|
||||||
Man $1 |
|
|
||||||
only |
|
|
||||||
set scrolloff=999 |
|
|
||||||
normal M
|
|
||||||
"
|
|
||||||
else
|
else
|
||||||
command man "$@"
|
command man "$@"
|
||||||
fi
|
fi
|
||||||
|
|||||||
Reference in New Issue
Block a user