-
Notifications
You must be signed in to change notification settings - Fork 1
71 lines (61 loc) · 1.95 KB
/
Copy pathrelease.yml
File metadata and controls
71 lines (61 loc) · 1.95 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
name: Release
on:
push:
branches:
- main
workflow_dispatch:
concurrency: ${{ github.workflow }}-${{ github.ref }}
permissions:
contents: write
pull-requests: write
id-token: write # Required for OIDC/trusted publishing
jobs:
release:
name: Release
runs-on: ubuntu-latest
environment:
name: release
url: https://www.npmjs.com/package/h2m-parser
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 #v5.0.0
with:
fetch-depth: 0 # Fetch all history for changesets
persist-credentials: false
- name: Setup Bun
uses: oven-sh/setup-bun@735343b667d3e6f658f44d0eca948eb6282f2b76 # v2.0.2
with:
bun-version: latest
- name: Setup Node.js
uses: actions/setup-node@a0853c24544627f65ddf259abe73b1d18a591444 #v5.0.0
with:
node-version: 24
registry-url: 'https://registry.npmjs.org'
always-auth: true
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Verify build
run: |
bun lint
bun typecheck
bun test
bun run build
- name: Create Release Pull Request or Publish
id: changesets
uses: changesets/action@e0145edc7d9d8679003495b11f87bd8ef63c0cba #v1.5.3
with:
publish: bun changeset publish
version: bun changeset version
commit: 'chore(release): version packages'
title: 'chore(release): version packages'
createGithubReleases: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_CONFIG_PROVENANCE: 'true'
- name: Publish notification
if: steps.changesets.outputs.published == 'true'
run: |
echo "🎉 Published packages:"
echo "$PUBLISHED_PACKAGES"
env:
PUBLISHED_PACKAGES: ${{ steps.changesets.outputs.publishedPackages }}