diff --git a/.github/workflows/formatting.yaml b/.github/workflows/formatting.yaml deleted file mode 100644 index f0c3310d..00000000 --- a/.github/workflows/formatting.yaml +++ /dev/null @@ -1,17 +0,0 @@ -name: stylua -on: - push: - branches: - - dev - paths-ignore: - - ".github/**" - -jobs: - stylua: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - uses: JohnnyMorganz/stylua-action@1.0.0 - with: - token: ${{ secrets.GITHUB_TOKEN }} - args: --check --config-path=stylua.toml . diff --git a/.github/workflows/formatting.yml b/.github/workflows/formatting.yml new file mode 100644 index 00000000..b37562e0 --- /dev/null +++ b/.github/workflows/formatting.yml @@ -0,0 +1,16 @@ +name: stylua +on: + push: + branches: ["main", "dev"] + paths-ignore: + - ".github/**" + +jobs: + stylua: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: JohnnyMorganz/stylua-action@1.0.0 + with: + token: ${{ secrets.GITHUB_TOKEN }} + args: --check --config-path=stylua.toml . diff --git a/README.md b/README.md index 7f48b05e..b49f1a9e 100644 --- a/README.md +++ b/README.md @@ -132,12 +132,12 @@ integrations = { telescope = true, nvimtree = { enabled = true, - show_root = false, + show_root = true, transparent_panel = false, }, neotree = { enabled = false, - show_root = false, + show_root = true, transparent_panel = false, }, which_key = false, @@ -262,10 +262,10 @@ let g:lightline = {'colorscheme': 'catppuccin'} ```lua require('lualine').setup { - options = { - theme = "catppuccin" - -- ... the rest of your lualine config - } + options = { + theme = "catppuccin" + -- ... the rest of your lualine config + } } ``` @@ -274,22 +274,22 @@ require('lualine').setup { ```lua integration = { - nvimtree = { - enabled = true, - show_root = true, -- makes the root folder not transparent - transparent_panel = false, -- make the panel transparent - } + nvimtree = { + enabled = true, + show_root = true, -- makes the root folder not transparent + transparent_panel = false, -- make the panel transparent + } } ``` - **Neo-tree:** setting `enabled` to `true` enables this integration: ```lua integration = { - neotree = { - enabled = true, - show_root = true, -- makes the root folder not transparent - transparent_panel = false, -- make the panel transparent - } + neotree = { + enabled = true, + show_root = true, -- makes the root folder not transparent + transparent_panel = false, -- make the panel transparent + } } ``` @@ -312,14 +312,14 @@ By default catppuccin writes the compiled results into the system's cache direct Catppuccin provides these commands to work with the catppuccin compiler. -```vim +```bash :CatppuccinCompile # Create/update the compile file :CatppuccinClean # Delete compiled file ``` It's recommended to add `:CatppuccinCompile` to run everytime you update your config. For example: -``` +```lua use { "catppuccin/nvim", as = "catppuccin", @@ -327,6 +327,19 @@ use { } ``` +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, +}) +``` + Acknowledge: [nightfox.nvim#compile](https://github.com/EdenEast/nightfox.nvim#compile) ### Extra @@ -370,9 +383,9 @@ Colors can be overwritten using `vim.g.catppucin_override_colors`: ```lua vim.g.catppuccin_override_colors = { - base = "#ff0000", - mantle = "#242424", - crust = "#474747", + base = "#ff0000", + mantle = "#242424", + crust = "#474747", } ``` @@ -401,11 +414,11 @@ Instead of `after_loading` hook, you can use autocmd event like this: ```lua vim.api.nvim_create_autocmd("User", { - pattern = "CatppuccinLoaded", - callback = function() - local colors = require("catppuccin.api.colors").get_colors() - -- do something with colors - end + pattern = "CatppuccinLoaded", + callback = function() + local colors = require("catppuccin.api.colors").get_colors() + -- do something with colors + end }) ``` diff --git a/lua/catppuccin/config.lua b/lua/catppuccin/config.lua index fefdf565..3d9ebae8 100644 --- a/lua/catppuccin/config.lua +++ b/lua/catppuccin/config.lua @@ -59,7 +59,7 @@ config.options = { }, neotree = { enabled = false, - show_root = false, + show_root = true, transparent_panel = false, }, which_key = false,