From 279ceccf6e210bb4e70e4e2d685cb5d014f86f89 Mon Sep 17 00:00:00 2001 From: nullchilly Date: Fri, 15 Jul 2022 22:06:32 +0700 Subject: [PATCH] chore(readme): Formatting --- README.md | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/README.md b/README.md index 7f36e38..f6ca4d4 100644 --- a/README.md +++ b/README.md @@ -335,10 +335,12 @@ use { Plug 'catppuccin/nvim', {'as': 'catppuccin', 'do': 'CatppuccinCompile'} ``` -- To auto-compile catppuccin after `:PackerCompile`, create an autocmd `User PackerCompileDone` in User group +- To auto-compile everytime you update your config: #### Packer.nvim +Create an autocmd `User PackerCompileDone` to update it + ```lua vim.api.nvim_create_autocmd("User", { pattern = "PackerCompileDone", @@ -350,21 +352,10 @@ vim.api.nvim_create_autocmd("User", { #### Vim-plug -```lua -autocmd User VimPlugDone :CatppuccinCompile -``` - -To auto-compile catppuccin after `:PackerCompile`, create an autocmd `PackerCompileDone` in User group - -For example, if your plugin specification is in `~/.config/nvim/lua/plugins.lua` then the pattern is `plugins.lua` +- ```lua -vim.api.nvim_create_autocmd("User PackerCompileDone", { - pattern = "plugins.lua", - callback = function() - vim.cmd "CatppuccinCompile" - end, -}) +autocmd BufWritePost init.vim :CatppuccinCompile ``` Acknowledge: [nightfox.nvim#compile](https://github.com/EdenEast/nightfox.nvim#compile)