Skip to content

Commit

Permalink
feat(lazygit): add template for lazygit extra
Browse files Browse the repository at this point in the history
  • Loading branch information
thesimonho committed Feb 25, 2025
1 parent 3649e8b commit c8b7cdf
Show file tree
Hide file tree
Showing 6 changed files with 54 additions and 3 deletions.
1 change: 1 addition & 0 deletions lua/kanagawa-paper/extras/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ M.extras = {
fzf = { ext = "sh", url = "https://github.com/junegunn/fzf/tree/master#environment-variables", label = "Fzf" },
ghostty = { ext = "", url = "https://github.com/ghostty-org/ghostty", label = "Ghostty" },
kitty = { ext = "conf", url = "https://sw.kovidgoyal.net/kitty/conf.html", label = "Kitty" },
lazygit = { ext = "yml", url = "https://github.com/jesseduffield/lazygit", label = "lazygit" },
terminator = { ext = "conf", url = "https://gnome-terminator.readthedocs.io/en/latest/config.html", label = "Terminator" },
termux = { ext = "properties", url = "https://termux.dev/", label = "Termux" },
tilix = { ext = "jsonc", url = "https://github.com/gnunn1/tilix", label = "Tilix" },
Expand Down
47 changes: 47 additions & 0 deletions lua/kanagawa-paper/extras/lazygit.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
local util = require("kanagawa-paper.lib.util")

local M = {}

--- @param colors ThemeColors
function M.generate(colors)
local lazygit = util.template(
[[
# -----------------------------------------------------------------------------
# ${_style_name}
# Upstream: ${_upstream_url}
# URL: ${_url}
# -----------------------------------------------------------------------------
gui:
theme:
activeBorderColor:
- "${modes.normal}"
- "bold"
inactiveBorderColor:
- "${ui.border}"
searchingActiveBorderColor:
- "${ui.bg_search}"
- "bold"
optionsTextColor:
- "${ui.special}"
selectedLineBgColor:
- "${ui.bg_cursorline}"
cherryPickedCommitFgColor:
- "${ui.fg_dim}"
cherryPickedCommitBgColor:
- "${modes.replace}"
markedBaseCommitFgColor:
- "${ui.fg_dim}"
markedBaseCommitBgColor:
- "${modes.normal}"
unstagedChangesColor:
- "${vcs.changed}"
defaultFgColor:
- "${ui.fg}"
]],
colors
)
return lazygit
end

return M
6 changes: 3 additions & 3 deletions lua/kanagawa-paper/extras/wezterm.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ cursor_bg = "${modes.normal}"
cursor_border = "${modes.normal}"
cursor_fg = "${ui.bg}"
selection_bg = "${ui.bg_visual}"
selection_fg = "${ui.fg_gray}"
selection_fg = "${ui.fg_dim}"
split = "${ui.win_separator}"
compose_cursor = "${ui.special}"
scrollbar_thumb = "${ui.scrollbar}"
Expand All @@ -32,7 +32,7 @@ ansi = [
"${term.blue}",
"${term.magenta}",
"${term.cyan}",
"${term.white}"
"${term.white}",
]
brights = [
"${term.black_bright}",
Expand All @@ -42,7 +42,7 @@ brights = [
"${term.blue_bright}",
"${term.magenta_bright}",
"${term.cyan_bright}",
"${term.white_bright}"
"${term.white_bright}",
]
[colors.indexed]
Expand Down
1 change: 1 addition & 0 deletions lua/kanagawa-paper/themes/canvas.lua
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ M.get = function(opts, palette)
bg_cursorline = palette.canvasWhite1,
bg_visual = palette.canvasViolet1,
bg_statusline = palette.canvasWhite0,
border = palette.canvasGray4,
header1 = palette.canvasBlue3,
header2 = palette.canvasOrange,
special = palette.canvasTeal1,
Expand Down
1 change: 1 addition & 0 deletions lua/kanagawa-paper/themes/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@
---@field bg_cursorline ColorSpec CursorLine background
---@field bg_visual ColorSpec Visual selection background
---@field bg_statusline ColorSpec Statusline background
---@field border ColorSpec Border color
---@field header1 ColorSpec Header1 text
---@field header2 ColorSpec Header2 text
---@field special ColorSpec SpecialKey
Expand Down
1 change: 1 addition & 0 deletions lua/kanagawa-paper/themes/ink.lua
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ M.get = function(opts, palette)
bg_cursorline = palette.sumiInk5,
bg_visual = palette.lotusViolet2,
bg_statusline = palette.sumiInk4,
border = palette.dragonBlack5,
header1 = palette.dragonViolet,
header2 = palette.dragonOrange,
special = palette.dragonAqua,
Expand Down

0 comments on commit c8b7cdf

Please # to comment.