Skip to content

Commit

Permalink
ci: validate the dist folder
Browse files Browse the repository at this point in the history
  • Loading branch information
aminya committed Mar 30, 2024
1 parent 73f20e6 commit 6887f00
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/check-dist.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Check Dist

on:
pull_request:
push:

permissions:
contents: read

jobs:
check-dist:
name: Check dist/
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: 20

- uses: pnpm/action-setup@v3
with:
version: 8

- name: Install and Build
run: pnpm i

- name: Validate Dist
id: diff
run: |
if [ "$(git diff --ignore-space-at-eol --text dist/ | wc -l)" -gt "0" ]; then
echo "Detected uncommitted changes after build. See status below:"
git diff --ignore-space-at-eol --text dist/
exit 1
fi

0 comments on commit 6887f00

Please sign in to comment.