Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 23 additions & 19 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,43 +1,47 @@
name: Release

on:
push:
branches:
- master
- main
- beta

jobs:
build:
# Important this runs on Github Actions infra
# npm publish will fail anywhere else (e.g. blacksmith)
runs-on: ubuntu-latest
# https://docs.npmjs.com/trusted-publishers#github-actions-configuration
permissions:
id-token: write # Required for npm OIDC
contents: write # Required for semantic-release to create releases/tags
issues: write # Required for semantic-release to comment on issues
pull-requests: write # Required for semantic-release to comment on PRs
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false

- name: Use Node.js 20
uses: actions/setup-node@v3
with:
node-version: 20.x
- name: Setup pnpm
uses: pnpm/action-setup@v4

- name: Cache node modules
uses: actions/cache@v3
- name: Use Node.js
uses: actions/setup-node@v4
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
node-version: 22
cache: pnpm
registry-url: https://registry.npmjs.org

- name: Install
run: npm install

- name: Unit Tests
run: npm run test
env:
CYPRESS_API_KEY: ${{ secrets.API_KEY }}
run: pnpm install --frozen-lockfile

- name: Build
run: npm run build
run: pnpm build

- name: Unit Tests
run: pnpm test

- name: Semantic Release
run: npm run semantic-release
# Use npx instead of pnpm to ensure npm OIDC token is passed correctly
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -725,7 +725,7 @@ this package is consumed by a code generator.

Any changes, including backwards incompatible changes will be listed here

## master
## main

- Fix error response schema on `/postcodes/:postcode`

Expand Down
Loading