Skip to content

Commit 304a662

Browse files
committed
feat(extras): add Alacritty theme
1 parent 1943ed2 commit 304a662

File tree

2 files changed

+52
-0
lines changed

2 files changed

+52
-0
lines changed
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
local util = require "astrotheme.extras"
2+
3+
local M = {}
4+
5+
--- @param colors AstroThemePalette
6+
function M.generate(colors)
7+
return util.template(
8+
[=[
9+
# AstroTheme Alacritty Colors
10+
# Default colors
11+
[colors.primary]
12+
background = '${ui.base}'
13+
foreground = '${ui.text}'
14+
15+
# Normal colors
16+
[colors.normal]
17+
black = '${term.black}'
18+
red = '${term.red}'
19+
green = '${term.green}'
20+
yellow = '${term.yellow}'
21+
blue = '${term.blue}'
22+
magenta = '${term.purple}'
23+
cyan = '${term.cyan}'
24+
white = '${term.white}'
25+
26+
# Bright colors
27+
[colors.bright]
28+
black = '${term.bright_black}'
29+
red = '${term.bright_red}'
30+
green = '${term.bright_green}'
31+
yellow = '${term.bright_yellow}'
32+
blue = '${term.bright_blue}'
33+
magenta = '${term.bright_purple}'
34+
cyan = '${term.bright_cyan}'
35+
white = '${term.bright_white}'
36+
37+
# Indexed Colors
38+
[[colors.indexed_colors]]
39+
index = 16
40+
color = '${ui.orange}'
41+
42+
[[colors.indexed_colors]]
43+
index = 17
44+
color = '${ui.red}'
45+
46+
]=],
47+
colors
48+
)
49+
end
50+
51+
return M

lua/astrotheme/extras/init.lua

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ M.extras = {
1212
lua = { ext = "lua", url = "https://www.lua.org", label = "Lua Table for testing" },
1313
vim = { ext = "vim", url = "https://vimhelp.org/", label = "Vim", subdir = "colors"},
1414
wezterm = { ext = "toml", url = "https://wezfurlong.org/wezterm/config/files.html", label = "WezTerm" },
15+
alacritty = { ext = "toml", url = "https://github.com/alacritty/alacritty", label = "Alacritty" },
1516
}
1617

1718
function M.setup()

0 commit comments

Comments
 (0)