Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(diffview): add diffview integrations #700

Merged
merged 3 commits into from
May 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -472,6 +472,20 @@ dashboard = true
</tr>
<!-- dashboard-nvim -->

<!-- diffview.nvim -->
</tr>
<tr>
<td> <a href="https://github.com/sindrets/diffview.nvim">diffview.nvim</a> </td>
<td>

```lua
diffview = false
```

</td>
</tr>
<!-- diffview.nvim -->

<!-- dropbar.nvim -->
</tr>
<tr>
Expand Down
4 changes: 4 additions & 0 deletions doc/catppuccin.txt
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,10 @@ dashboard-nvim>lua
dashboard = true
<

diffview.nvim>lua
diffview = false


dropbar.nvim>lua
dropbar = {
enabled = false,
Expand Down
41 changes: 41 additions & 0 deletions lua/catppuccin/groups/integrations/diffview.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
local M = {}

function M.get()
return {
DiffviewDim1 = { link = "Comment" },
DiffviewPrimary = { fg = C.blue },
DiffviewSecondary = { fg = C.green },
DiffviewNormal = { fg = C.text, bg = O.transparent_background and C.none or C.mantle },
DiffviewWinSeparator = {
fg = O.transparent_background and C.surface1 or C.base,
bg = O.transparent_background and C.none or C.base,
},
DiffviewFilePanelTitle = { fg = C.blue, style = { "bold" } },
DiffviewFilePanelCounter = { fg = C.text },
DiffviewFilePanelRootPath = { fg = C.lavender, style = { "bold" } },
DiffviewFilePanelFileName = { fg = C.text },
DiffviewFilePanelSelected = { fg = C.yellow },
DiffviewFilePanelPath = { link = "Comment" },
DiffviewFilePanelInsertions = { fg = C.green },
DiffviewFilePanelDeletions = { fg = C.red },
DiffviewFilePanelConflicts = { fg = C.yellow },
DiffviewFolderName = { fg = C.blue, style = { "bold" } },
DiffviewFolderSign = { fg = C.blue },
DiffviewHash = { fg = C.flamingo },
DiffviewReference = { fg = C.blue, style = { "bold" } },
DiffviewReflogSelector = { fg = C.pink },
DiffviewStatusAdded = { fg = C.green },
DiffviewStatusUntracked = { fg = C.green },
DiffviewStatusModified = { fg = C.yellow },
DiffviewStatusRenamed = { fg = C.yellow },
DiffviewStatusCopied = { fg = C.yellow },
DiffviewStatusTypeChange = { fg = C.yellow },
DiffviewStatusUnmerged = { fg = C.yellow },
DiffviewStatusUnknown = { fg = C.red },
DiffviewStatusDeleted = { fg = C.red },
DiffviewStatusBroken = { fg = C.red },
DiffviewStatusIgnored = { fg = C.overlay0 },
}
end

return M
1 change: 1 addition & 0 deletions lua/catppuccin/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ local M = {
dap = true,
dap_ui = true,
dashboard = true,
diffview = false,
flash = true,
gitsigns = true,
markdown = true,
Expand Down
1 change: 1 addition & 0 deletions lua/catppuccin/types.lua
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@
---@field dap boolean?
---@field dap_ui boolean?
---@field dashboard boolean?
---@field diffview boolean?
---@field dropbar CtpIntegrationDropbar | boolean?
---@field fern boolean?
-- Set `notification.window.winblend` to `0` in your `fidget` config:
Expand Down
Loading