Skip to content

Commit 3760a4d

Browse files
authored
chore: add changesets release action (#208)
1 parent cc7dbbd commit 3760a4d

File tree

2 files changed

+37
-28
lines changed

2 files changed

+37
-28
lines changed

Diff for: .github/workflows/NpmPublish.yml

-28
This file was deleted.

Diff for: .github/workflows/Release.yml

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
release:
10+
name: Release
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout Repo
14+
uses: actions/checkout@v3
15+
with:
16+
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
17+
fetch-depth: 0
18+
19+
- name: Setup Node.js 16
20+
uses: actions/setup-node@v3
21+
with:
22+
node-version: 16
23+
24+
- name: Install Dependencies
25+
run: yarn
26+
27+
- name: Create Release Pull Request or Publish to npm
28+
id: changesets
29+
uses: changesets/action@v1
30+
with:
31+
# This expects you to have a script called release which does a build for your packages and calls changeset publish
32+
publish: yarn release
33+
commit: "chore: release svelte-eslint-parser"
34+
title: "chore: release svelte-eslint-parser"
35+
env:
36+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
37+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

0 commit comments

Comments
 (0)