Merge commit 'HEAD@{1}' into develop

This commit is contained in:
Foo 2015-04-03 22:42:41 +03:00
commit 364fc4dcd9
1 changed files with 11 additions and 9 deletions

View File

@ -227,21 +227,23 @@ If your vimrc has something like
.. code-block:: vim
autocmd! BufWritePost vimrc :source ~/.vimrc
autocmd! BufWritePost ~/.vimrc :source ~/.vimrc
to automatically source vimrc after saving it you must then add ``nested`` after
pattern (``vimrc`` in this case):
used to automatically source vimrc after saving it then you must add ``nested``
after pattern (``vimrc`` in this case):
.. code-block:: vim
autocmd! BufWritePost vimrc nested :source ~/.vimrc
autocmd! BufWritePost ~/.vimrc nested :source ~/.vimrc
. Alternatively move ``:colorscheme`` command out of the vimrc to the file which
will not be automatically resourced. Observed problem is that when you use
``:colorscheme`` command existing highlighting groups are usually cleared,
including those defined by powerline. To workaround this issue powerline hooks
``Colorscheme`` event, but when you source vimrc with ``BufWritePost`` event,
but without ``nested`` this event is not launched. See also `autocmd-nested
will not be automatically resourced.
Observed problem is that when you use ``:colorscheme`` command existing
highlighting groups are usually cleared, including those defined by powerline.
To workaround this issue powerline hooks ``Colorscheme`` event, but when you
source vimrc with ``BufWritePost`` (or any other) event, but without ``nested``
this event is not launched. See also `autocmd-nested
<http://vimpluginloader.sourceforge.net/doc/autocmd.txt.html#autocmd-nested>`_
Vim documentation.