@@ -41,12 +41,12 @@ jobs:
4141 token : ${{ secrets.GITHUB_TOKEN }}
4242 version : latest
4343 args : --check .
44-
45- test :
44+ test-neovim :
4645 name : Test Neovim Config
47- runs-on : ubuntu-latest
46+ runs-on : ${{ matrix.os }}
4847 strategy :
4948 matrix :
49+ os : [ubuntu-latest, macos-latest, windows-latest]
5050 nvim_version : ["stable", "nightly"]
5151 steps :
5252 - name : Checkout code
@@ -58,11 +58,74 @@ jobs:
5858 neovim : true
5959 version : ${{ matrix.nvim_version }}
6060
61- - name : Test config loads
61+ - name : Test config loads (Unix)
62+ if : matrix.os != 'windows-latest'
6263 run : |
6364 nvim --version
6465 nvim --headless -c "quit" 2>&1 | tee /tmp/nvim-test.log
6566 if grep -i "error" /tmp/nvim-test.log; then
6667 echo "Config has errors!"
6768 exit 1
6869 fi
70+
71+ - name : Test config loads (Windows)
72+ if : matrix.os == 'windows-latest'
73+ shell : powershell
74+ run : |
75+ nvim --version
76+ nvim --headless -c "quit" 2>&1 | Tee-Object -FilePath nvim-test.log
77+ if (Select-String -Path nvim-test.log -Pattern "error" -Quiet) {
78+ Write-Error "Config has errors!"
79+ exit 1
80+ }
81+
82+ test-wezterm :
83+ name : Test WezTerm Config
84+ runs-on : ${{ matrix.os }}
85+ strategy :
86+ matrix :
87+ os : [ubuntu-latest, macos-latest, windows-latest]
88+ steps :
89+ - name : Checkout code
90+ uses : actions/checkout@v4
91+
92+ - name : Install WezTerm (Ubuntu)
93+ if : matrix.os == 'ubuntu-latest'
94+ run : |
95+ curl -fsSL https://apt.fury.io/wez/gpg.key | sudo gpg --yes --dearmor -o /usr/share/keyrings/wezterm-fury.gpg
96+ echo 'deb [signed-by=/usr/share/keyrings/wezterm-fury.gpg] https://apt.fury.io/wez/ * *' | sudo tee /etc/apt/sources.list.d/wezterm.list
97+ sudo apt update
98+ sudo apt install -y wezterm
99+
100+ - name : Install WezTerm (macOS)
101+ if : matrix.os == 'macos-latest'
102+ run : brew install --cask wezterm
103+
104+ - name : Install WezTerm (Windows)
105+ if : matrix.os == 'windows-latest'
106+ run : choco install wezterm -y
107+
108+ - name : Test WezTerm config (Unix)
109+ if : matrix.os != 'windows-latest'
110+ run : |
111+ mkdir -p ~/.config/wezterm
112+ ln -sf ${{ github.workspace }}/wezterm.lua ~/.config/wezterm/wezterm.lua
113+ wezterm --version
114+ wezterm ls-fonts 2>&1 | tee /tmp/wezterm-test.log
115+ if grep -i "error" /tmp/wezterm-test.log; then
116+ echo "WezTerm config has errors!"
117+ exit 1
118+ fi
119+
120+ - name : Test WezTerm config (Windows)
121+ if : matrix.os == 'windows-latest'
122+ shell : powershell
123+ run : |
124+ New-Item -ItemType Directory -Force -Path $env:USERPROFILE\.config\wezterm
125+ Copy-Item ${{ github.workspace }}\wezterm.lua $env:USERPROFILE\.config\wezterm\wezterm.lua
126+ wezterm --version
127+ wezterm ls-fonts 2>&1 | Tee-Object -FilePath wezterm-test.log
128+ if (Select-String -Path wezterm-test.log -Pattern "error" -Quiet) {
129+ Write-Error "WezTerm config has errors!"
130+ exit 1
131+ }
0 commit comments