feat(windows terminal): supported (#68)
* feat(windows terminal): hello world * fix(windows terminal): magenta * fix(windows_terminal): wrong bright black var, missing dir (close #67) * fix(windows_terminal): cursor color * ref(windowns terminal): order by content, no comment * Update lua/zenbones/shipwright/runners/windows_terminal.lua Co-authored-by: Michael Chris Lopez <hello@michaelchris.space> * fix(windows_terminal): theme name Co-authored-by: Michael Chris Lopez <hello@michaelchris.space>
This commit is contained in:
@@ -77,7 +77,7 @@ local function make_runners(config)
|
||||
end
|
||||
|
||||
M.run = function()
|
||||
local runner_files = { "vim", "iterm", "alacritty", "kitty", "wezterm", "tmux", "lualine", "lightline" }
|
||||
local runner_files = { "vim", "iterm", "alacritty", "kitty", "wezterm", "tmux", "windows_terminal", "lualine", "lightline" }
|
||||
local colorschemes = vim.fn.json_decode(vim.fn.readfile "zenbones.json")
|
||||
for _, colorscheme in ipairs(colorschemes) do
|
||||
for _, file in ipairs(runner_files) do
|
||||
|
||||
43
lua/zenbones/shipwright/runners/windows_terminal.lua
Normal file
43
lua/zenbones/shipwright/runners/windows_terminal.lua
Normal file
@@ -0,0 +1,43 @@
|
||||
local template = [[{
|
||||
"name": "$name",
|
||||
"foreground": "$fg",
|
||||
"background": "$bg",
|
||||
"selectionBackground": "$selection_bg",
|
||||
"cursorColor": "$cursor_bg",
|
||||
"black": "$black",
|
||||
"red": "$red",
|
||||
"green": "$green",
|
||||
"yellow": "$yellow",
|
||||
"blue": "$blue",
|
||||
"purple": "$magenta",
|
||||
"cyan": "$cyan",
|
||||
"white": "$white",
|
||||
"brightBlack": "$bright_black",
|
||||
"brightRed": "$bright_red",
|
||||
"brightGreen": "$bright_green",
|
||||
"brightYellow": "$bright_yellow",
|
||||
"brightBlue": "$bright_blue",
|
||||
"brightPurple": "$bright_magenta",
|
||||
"brightCyan": "$bright_cyan",
|
||||
"brightWhite": "$bright_white"
|
||||
}
|
||||
]]
|
||||
|
||||
local helpers = require "shipwright.transform.helpers"
|
||||
|
||||
---@diagnostic disable: undefined-global
|
||||
-- selene: allow(undefined_variable)
|
||||
run(
|
||||
{ specs, p, term },
|
||||
transform.colorscheme_to_term_colors,
|
||||
function(colors)
|
||||
return vim.tbl_extend("keep", colors, { name = name })
|
||||
end,
|
||||
function(colors)
|
||||
local text = helpers.apply_template(template, colors)
|
||||
return { text }
|
||||
end,
|
||||
{ overwrite, string.format("extras/windows_terminal/%s.json", name) }
|
||||
)
|
||||
-- selene: deny(undefined_variable)
|
||||
---@diagnostic enable: undefined-global
|
||||
Reference in New Issue
Block a user