Skip to content

Commit d405424

Browse files
anbratenlukashass
andauthored
ci: add release workflow (#10)
Co-authored-by: Lukas <[email protected]>
1 parent ff10715 commit d405424

File tree

4 files changed

+1741
-57
lines changed

4 files changed

+1741
-57
lines changed

.github/workflows/release.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
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
14+
uses: actions/checkout@v2
15+
with:
16+
fetch-depth: 0
17+
18+
- uses: actions/setup-node@v2
19+
with:
20+
node-version: '14'
21+
22+
- name: Cache pnpm modules
23+
uses: actions/cache@v2
24+
env:
25+
cache-name: cache-pnpm-modules
26+
with:
27+
path: ~/.pnpm-store
28+
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ matrix.node-version }}-${{ hashFiles('**/package.json') }}
29+
restore-keys: |
30+
${{ runner.os }}-build-${{ env.cache-name }}-${{ matrix.node-version }}-
31+
32+
- uses: pnpm/[email protected]
33+
with:
34+
version: 6
35+
run_install: true
36+
37+
- name: Build
38+
run: pnpm build
39+
40+
- name: Release
41+
env:
42+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
43+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
44+
run: pnpm release

.releaserc.json

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"plugins": [
3+
"@semantic-release/commit-analyzer",
4+
"@semantic-release/release-notes-generator",
5+
["@semantic-release/npm", { "npmPublish": true }],
6+
"@semantic-release/github"
7+
],
8+
"branches": ["main"]
9+
}

package.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@geprog/eslint-config",
3-
"version": "0.2.0",
3+
"version": "0.0.0-semantic-release",
44
"description": "ESLint config for Typescript, Vue.js and Jest",
55
"homepage": "https://geprog.com",
66
"repository": "github:geprog/eslint-config",
@@ -33,8 +33,13 @@
3333
"vue-eslint-parser": "7.6.0"
3434
},
3535
"devDependencies": {
36+
"@semantic-release/commit-analyzer": "8.0.1",
37+
"@semantic-release/github": "7.2.3",
38+
"@semantic-release/npm": "7.1.3",
39+
"@semantic-release/release-notes-generator": "9.0.3",
3640
"@typescript-eslint/experimental-utils": "4.28.1",
3741
"prettier": "2.3.2",
42+
"semantic-release": "17.4.4",
3843
"typescript": "4.3.5"
3944
},
4045
"peerDependencies": {

0 commit comments

Comments
 (0)