Skip to content

Commit

Permalink
feat(integrations): add mason.nvim
Browse files Browse the repository at this point in the history
  • Loading branch information
emxxjnm authored and emxxjnm committed Oct 14, 2022
1 parent 4878d6e commit e1e7f18
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 0 deletions.
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,7 @@ Below is a list of supported plugins and their corresponding integration module.
| [lightspeed.nvim](https://github.com/ggandor/lightspeed.nvim) | lightspeed |
| [lspsaga.nvim](https://github.com/glepnir/lspsaga.nvim/) | lsp_saga |
| [lualine.nvim](https://github.com/nvim-lualine/lualine.nvim) | Special |
| [mason](https://github.com/williamboman/mason.nvim) | mason |
| [markdown](https://www.markdownguide.org/) | markdown |
| [mini.nvim](https://github.com/echasnovski/mini.nvim) | mini |
| [neo-tree.nvim](https://github.com/nvim-neo-tree/neo-tree.nvim) | neotree |
Expand Down Expand Up @@ -239,6 +240,7 @@ require("catppuccin").setup({
lightspeed = false,
lsp_saga = false,
lsp_trouble = false,
mason = true,
markdown = true,
mini = false,
neogit = false,
Expand Down
38 changes: 38 additions & 0 deletions lua/catppuccin/groups/integrations/mason.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
local M = {}

function M.get()
local bg = cnf.transparent_background and cp.none or cp.lavender
local fg = cnf.transparent_background and cp.lavender or cp.base

local secondary_bg = cnf.transparent_background and cp.none or cp.blue
local secondary_fg = cnf.transparent_background and cp.blue or cp.base

local muted_bg = cnf.transparent_background and cp.none or cp.overlay0
local muted_fg = cnf.transparent_background and cp.overlay0 or cp.base

return {
MasonHeader = { fg = fg, bg = bg, style = { "bold" } },
MasonHeaderSecondary = { fg = secondary_fg, bg = secondary_bg, style = { "bold" } },

MasonHighlight = { fg = cp.green },
MasonHighlightBlock = {
bg = cnf.transparent_background and cp.none or cp.green,
fg = cnf.transparent_background and cp.green or cp.base,
},
MasonHighlightBlockBold = { bg = secondary_bg, fg = secondary_fg, bold = true },

MasonHighlightSecondary = { fg = cp.mauve },
MasonHighlightBlockSecondary = { fg = secondary_fg, bg = secondary_bg },
MasonHighlightBlockBoldSecondary = { fg = fg, bg = bg, bold = true },

MasonMuted = { fg = cp.overlay0 },
MasonMutedBlock = { bg = muted_bg, fg = muted_fg },
MasonMutedBlockBold = { bg = cp.yellow, fg = cp.base, bold = true },

MasonError = { fg = cp.red },

MasonHeading = { fg = cp.lavender, bold = true },
}
end

return M

0 comments on commit e1e7f18

Please sign in to comment.