-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (35 loc) · 1 KB
/
Copy pathchangesets-publish.yml
File metadata and controls
43 lines (35 loc) · 1 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
name: Publish Changesets
on:
push:
branches:
- main
permissions:
contents: write
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Setup Go
uses: actions/setup-go@v6
with:
go-version-file: go.mod
- name: Install tools
run: go install tool
- name: Validate release prerequisites
run: |
test -f go.work || (echo "go.work missing" && exit 1)
test -f version.txt || (echo "version.txt missing" && exit 1)
- name: Regenerate SDK
run: make all
- name: Publish tags and GitHub release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
REPO_OWNER: ${{ github.repository_owner }}
REPO_NAME: ${{ github.event.repository.name }}
run: |
changeset each --filter outdated-versions -- \
changeset publish --owner "$REPO_OWNER" --repo "$REPO_NAME"