Skip to content

Commit 7fc16e0

Browse files
author
Antigravity
committed
Updating the release github action workflow to fail if docgap does not pass before releasing CLI and Action.
1 parent 2b376f8 commit 7fc16e0

1 file changed

Lines changed: 30 additions & 0 deletions

File tree

.github/workflows/release.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,37 @@ on:
77
- main
88

99
jobs:
10+
dogfood:
11+
name: Pre-release Check
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
with:
16+
fetch-depth: 0
17+
- uses: pnpm/action-setup@v2
18+
with:
19+
version: 9
20+
- uses: actions/setup-node@v4
21+
with:
22+
node-version: '20'
23+
cache: 'pnpm'
24+
25+
- name: Install Dependencies
26+
run: pnpm install --frozen-lockfile
27+
28+
- name: Build Action
29+
run: pnpm --filter @docgap/action... build
30+
31+
- name: Run Drift Check (Dogfood)
32+
run: node apps/action/dist/index.js
33+
env:
34+
GITHUB_WORKSPACE: ${{ github.workspace }}
35+
INPUT_CONFIG: .docgap.yaml
36+
INPUT_STRICT: true
37+
1038
npm-publish:
1139
name: Publish to NPM
40+
needs: dogfood
1241
runs-on: ubuntu-latest
1342
permissions:
1443
contents: read
@@ -52,6 +81,7 @@ jobs:
5281

5382
action-release:
5483
name: Release GitHub Action
84+
needs: dogfood
5585
runs-on: ubuntu-latest
5686
permissions:
5787
contents: write

0 commit comments

Comments
 (0)