Skip to content

Commit f51d142

Browse files
ochafikclaude
andcommitted
ci: add Windows WSL build test
Uses Vampire/setup-wsl action to install Ubuntu-24.04 in WSL and run the full build/test cycle. This tests the Linux-in-Windows scenario that was reported in issue #142. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]>
1 parent cf69dc9 commit f51d142

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed

.github/workflows/ci.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,38 @@ jobs:
6363

6464
- run: npm run prettier
6565

66+
# Test build in Windows WSL (Ubuntu)
67+
build-wsl:
68+
name: Build (Windows WSL)
69+
runs-on: windows-latest
70+
71+
steps:
72+
- uses: actions/checkout@v4
73+
74+
- uses: Vampire/setup-wsl@v5
75+
with:
76+
distribution: Ubuntu-24.04
77+
78+
- name: Install dependencies in WSL
79+
shell: wsl-bash {0}
80+
run: |
81+
# Install Node.js and Bun
82+
curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash -
83+
sudo apt-get install -y nodejs
84+
curl -fsSL https://bun.sh/install | bash
85+
echo 'export BUN_INSTALL="$HOME/.bun"' >> ~/.bashrc
86+
echo 'export PATH="$BUN_INSTALL/bin:$PATH"' >> ~/.bashrc
87+
88+
- name: Build and test in WSL
89+
shell: wsl-bash {0}
90+
run: |
91+
export BUN_INSTALL="$HOME/.bun"
92+
export PATH="$BUN_INSTALL/bin:$PATH"
93+
npm install
94+
npm run build
95+
npm test
96+
npm run prettier
97+
6698
# Test that the package can be installed from git (triggers prepare script)
6799
test-git-install:
68100
strategy:

0 commit comments

Comments
 (0)