From 54f75b743857a1e2b8d5aa7e102d436c364b5642 Mon Sep 17 00:00:00 2001 From: Marco Hinz Date: Wed, 4 Jan 2017 19:37:39 +0100 Subject: [PATCH] MatchIt: add :packadd for Vim 8 --- README.md | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 7a4c7e7..c584da0 100644 --- a/README.md +++ b/README.md @@ -1830,12 +1830,18 @@ Vim comes bundled with a plugin called matchit.vim which is not enabled by default. It makes `%` also cycle through HTML tags, if/else/endif constructs in VimL etc. and introduces a few new commands. -To always load the plugin, put this in your vimrc: +#### Installation for Vim 8 ```vim -if !exists('g:loaded_matchit') - runtime macros/matchit.vim -endif +" vimrc +packadd! matchit +``` + +#### Installation for Vim 7 and older + +```vim +" vimrc +runtime macros/matchit.vim ``` Since the documentation of matchit is pretty extensive, I suggest also doing the @@ -1847,6 +1853,8 @@ following once: :helptags ~/.vim/doc ``` +#### Small intro + The plugin is ready to use now. See `:h matchit-intro` for the supported commands and `:h matchit-languages` for the supported languages.