Skip to content

Commit 9ae5b76

Browse files
authored
Merge pull request #31 from lottie/kn/faq_section
Fix build and CI add a pre-merge check on PRs
2 parents b7e6a45 + e235d24 commit 9ae5b76

6 files changed

Lines changed: 883 additions & 2586 deletions

File tree

.github/workflows/pr-check.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: PR Build Check
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
8+
# Cancel in-progress runs if a new commit is pushed to the PR
9+
concurrency:
10+
group: ${{ github.workflow }}-${{ github.ref }}
11+
cancel-in-progress: true
12+
13+
jobs:
14+
build-check:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Checkout
18+
uses: actions/checkout@v4
19+
20+
- name: Setup
21+
run: npm install
22+
23+
- name: Run build
24+
run: npm run build
25+
26+
- name: Check build artifacts
27+
run: |
28+
if [ ! -d "public" ]; then
29+
echo "Build failed: public directory not created"
30+
exit 1
31+
fi
32+
if [ ! -f "public/index.html" ]; then
33+
echo "Build failed: index.html not found"
34+
exit 1
35+
fi
36+
echo "Build successful: all artifacts present"

0 commit comments

Comments
 (0)