The statusline is only dynamically updated for the active buffer, thus
when there are multiple splits the statusline for inactive buffers may
include non-updated output of `coc#status()`. This patch adds a boolean
flag to `statusline#generic()` which enables `statusline#active()` and
`statusline#inactive()` to control when `coc#status()` is included in
the statusline.
When selecting a `:BuildDir` for the `clangd` LSP use `compdb` to
post-process the `compile_commands.json` to also include flags for
stand alone header files.
Symbolic links committed to Git repositories do not work on Windows.
Repalce the `init.vim` symbolic link with a regular file which loads
`vimrc`, this should work on all platforms.
Introduces the `format` Python module which provides `clang_format()`
and `yapf()` functions which efficiently (compared to vimscript) invoke
`clang-format` or `yapf` respectively then apply the minimal number of
changes using `difflib.SequenceMatcher`.
Additionally, in order to invoke these Python functions add |autoload|
functions `format#clang_format()` and `format#yapf()` which can be
directly used by the 'formatexpr' setting.
Finally, add |ftplugin| files which set 'formatexpr' when the |autoload|
functions are available.
Change the `K` normal mode overrides to use the example given in the
coc.nvim README file which uses Vim's builtin help when in `vim` or
`help` files, or checks if coc.nvim is ready and invokes
`CocActionAsync('doHover')`, otherwise fallback to using `keywordprg`.
Vim's :terminal feels much more ergonomic, adding various mappings to
make the experience more similar, mainly by adding a few `<C-w>`
mappings for the most common actions.
Additionally, disable vim-tmux-navigators default mappings and setup
both normal and terminal mode mappings for `<C-w>{h,j,k,l}` in addition
to the normal mode mappings for `<C-{h,j,j,l}>` to make the pane
switching experience more consistent across all buffer types.
Update `build#dir()` to check for the existence of the `.vim` directory
containing `coc_settings.json` before attempting to read the file. If it
doesn't exist then create it.