Skip to content

Commit a2ac744

Browse files
committed
👷 Add release config for github actions
1 parent ef5b6ea commit a2ac744

File tree

3 files changed

+34
-2
lines changed

3 files changed

+34
-2
lines changed

.github/workflows/release.yml

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Node.js Package
2+
3+
on:
4+
release:
5+
types: [created]
6+
push:
7+
tags:
8+
- '*'
9+
10+
jobs:
11+
build:
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- uses: actions/checkout@v2
16+
17+
- uses: actions/setup-node@v2
18+
with:
19+
node-version: '14.x'
20+
registry-url: 'https://registry.npmjs.org'
21+
22+
- name: Install dependencies & build packages
23+
run: yarn install --frozen-lockfile
24+
25+
- name: Run tests
26+
run: yarn test:ci
27+
28+
- name: Publish packages
29+
run: yarn release:beta
30+
env:
31+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN_TEST }}

.github/workflows/test.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: Node.js CI
33
on: [push, pull_request]
44

55
jobs:
6-
test:
6+
build:
77
runs-on: ubuntu-latest
88

99
steps:

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
"format": "prettier --config ./prettier.config.js --write 'packages/@ackee/*/src/**/*.ts' '*.{js,json}' --loglevel warn",
2424
"release": "lerna publish --no-push",
2525
"release:beta": "yarn release --dist-tag beta --no-push",
26+
"release:alpha": "yarn release --dist-tag alpha --no-push",
2627
"prepare": "yarn build",
2728
"release:yalc": "yarn prepare && lerna exec -- yalc push --no-scripts",
2829
"circular-modules": "lerna exec -- madge --circular src",
@@ -69,7 +70,7 @@
6970
"husky": {
7071
"hooks": {
7172
"pre-commit": "lint-staged",
72-
"pre-push": "yarn circular-modules && yarn docs:build && yarn docs:commit"
73+
"pre-push": "yarn circular-modules"
7374
}
7475
},
7576
"lint-staged": {

0 commit comments

Comments
 (0)