Skip to content

Commit

Permalink
ci: add beachball changefile check
Browse files Browse the repository at this point in the history
  • Loading branch information
frantic1048 committed Mar 8, 2024
1 parent 82c6f1e commit 8c9dea2
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 8 deletions.
51 changes: 43 additions & 8 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,22 +6,44 @@ on:
branches: [main]

jobs:
build:
install:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- uses: actions/[email protected]
with:
node-version-file: .node-version
cache: pnpm
- run: pnpm install

- name: Prepare pnpm
uses: pnpm/action-setup@v2

- name: Prepare Node.js
uses: actions/[email protected]
check-beachball-changefile:
if: github.base_ref == github.event.repository.default_branch
needs: install
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- uses: actions/[email protected]
with:
node-version-file: .node-version
cache: pnpm
- run: pnpm install

- name: Install deps
run: pnpm install
- name: Check
run: pnpm exec beachball check

test:
needs: install
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- uses: actions/[email protected]
with:
node-version-file: .node-version
cache: pnpm
- run: pnpm install

- name: ESLint
run: pnpm run eslint
Expand All @@ -32,6 +54,19 @@ jobs:
- name: Test
run: pnpm run test

build:
if: ${{ always() && !failure() && !cancelled() }}
needs: [test, check-beachball-changefile]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- uses: actions/[email protected]
with:
node-version-file: .node-version
cache: pnpm
- run: pnpm install

- name: Build
run: pnpm run build

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"comment": "ci: add beachball changefile check",
"type": "none",
"packageName": "@rightcapital/phpdoc-parser",
"email": "[email protected]",
"dependentChangeType": "none"
}

0 comments on commit 8c9dea2

Please sign in to comment.