Skip to content

Commit aabb735

Browse files
committed
feat(extras): add automatic generation of extras with templating
1 parent ad99418 commit aabb735

File tree

8 files changed

+182
-268
lines changed

8 files changed

+182
-268
lines changed

.github/workflows/astrotheme.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: AstroTheme
2+
on:
3+
push:
4+
branches: [main]
5+
pull_request:
6+
7+
jobs:
8+
tests:
9+
runs-on: ubuntu-latest
10+
strategy:
11+
matrix:
12+
nvim-version: ["stable", "nightly"]
13+
name: Test Neovim ${{ matrix.nvim-version }}
14+
steps:
15+
- uses: actions/checkout@v4
16+
- uses: rhysd/action-setup-vim@v1
17+
with:
18+
neovim: true
19+
version: ${{ matrix.nvim-version }}
20+
- run: make test
21+
build:
22+
runs-on: ubuntu-latest
23+
name: Build Extras
24+
needs: tests
25+
steps:
26+
- uses: actions/checkout@v4
27+
- uses: rhysd/action-setup-vim@v1
28+
with:
29+
neovim: true
30+
- run: make extras
31+
- name: Push changes
32+
if: ${{ github.event_name == 'push' }}
33+
uses: stefanzweifel/git-auto-commit-action@v5
34+
with:
35+
file_pattern: "extras/*"
36+
commit_message: "chore(extras): auto-generate extras"
37+
commit_user_name: "astronvimbot"
38+
commit_user_email: "github@astronvim.com"
39+
commit_author: "AstroNvim Bot <github@astronvim.com>"

.github/workflows/tests.yml

Lines changed: 0 additions & 20 deletions
This file was deleted.

Makefile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
TESTS_DIR=tests/
22

33
.PHONY: test
4-
54
test:
65
@nvim -l ${TESTS_DIR}/minit.lua --busted ${TESTS_DIR} -o utfTerminal
6+
7+
.PHONY: extras
8+
extras:
9+
@nvim -u ${TESTS_DIR}/minit.lua --headless +"lua require('astrotheme.extras').setup()" +qa

extras/wezterm/README.md

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,10 @@
11
# Wezterm
2-
1. Copy either `wezterm_astrodark.toml` or `wezterm_astrodark.lua` to `~/.config/wezterm/colors`
3-
2. Add either options to your Wezterm config.
42

5-
## If you want to use astrodark.toml
6-
```lua
7-
return {
8-
color_scheme = "Astrodark",
9-
}
10-
```
3+
1. Copy the `toml` files to `~/.config/wezterm/colors/`
4+
2. Add the following to your Wezterm config.
115

12-
## If you want to use astrodark.lua
136
```lua
14-
local astrodark = require("colors/astrodark")
157
return {
16-
colors = astrodark.colors(),
17-
window_frame = astrodark.window_frame(),
8+
color_scheme = "astrotheme_astrodark", -- or whichever palette you want
189
}
1910
```

extras/wezterm/wezterm_astrodark.lua

Lines changed: 0 additions & 156 deletions
This file was deleted.

extras/wezterm/wezterm_astrodark.toml

Lines changed: 0 additions & 79 deletions
This file was deleted.

0 commit comments

Comments
 (0)