|
|
@ -335,10 +335,12 @@ use {
|
|
|
|
Plug 'catppuccin/nvim', {'as': 'catppuccin', 'do': 'CatppuccinCompile'}
|
|
|
|
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
|
|
|
|
#### Packer.nvim
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Create an autocmd `User PackerCompileDone` to update it
|
|
|
|
|
|
|
|
|
|
|
|
```lua
|
|
|
|
```lua
|
|
|
|
vim.api.nvim_create_autocmd("User", {
|
|
|
|
vim.api.nvim_create_autocmd("User", {
|
|
|
|
pattern = "PackerCompileDone",
|
|
|
|
pattern = "PackerCompileDone",
|
|
|
@ -350,21 +352,10 @@ vim.api.nvim_create_autocmd("User", {
|
|
|
|
|
|
|
|
|
|
|
|
#### Vim-plug
|
|
|
|
#### 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
|
|
|
|
```lua
|
|
|
|
vim.api.nvim_create_autocmd("User PackerCompileDone", {
|
|
|
|
autocmd BufWritePost init.vim :CatppuccinCompile
|
|
|
|
pattern = "plugins.lua",
|
|
|
|
|
|
|
|
callback = function()
|
|
|
|
|
|
|
|
vim.cmd "CatppuccinCompile"
|
|
|
|
|
|
|
|
end,
|
|
|
|
|
|
|
|
})
|
|
|
|
|
|
|
|
```
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
Acknowledge: [nightfox.nvim#compile](https://github.com/EdenEast/nightfox.nvim#compile)
|
|
|
|
Acknowledge: [nightfox.nvim#compile](https://github.com/EdenEast/nightfox.nvim#compile)
|
|
|
|