Skip to content

Commit

Permalink
👷 Add release config for github actions
Browse files Browse the repository at this point in the history
  • Loading branch information
cermakjiri committed Sep 8, 2021
1 parent ef5b6ea commit a2ac744
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 2 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Node.js Package

on:
release:
types: [created]
push:
tags:
- '*'

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- uses: actions/setup-node@v2
with:
node-version: '14.x'
registry-url: 'https://registry.npmjs.org'

- name: Install dependencies & build packages
run: yarn install --frozen-lockfile

- name: Run tests
run: yarn test:ci

- name: Publish packages
run: yarn release:beta
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN_TEST }}
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Node.js CI
on: [push, pull_request]

jobs:
test:
build:
runs-on: ubuntu-latest

steps:
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
"format": "prettier --config ./prettier.config.js --write 'packages/@ackee/*/src/**/*.ts' '*.{js,json}' --loglevel warn",
"release": "lerna publish --no-push",
"release:beta": "yarn release --dist-tag beta --no-push",
"release:alpha": "yarn release --dist-tag alpha --no-push",
"prepare": "yarn build",
"release:yalc": "yarn prepare && lerna exec -- yalc push --no-scripts",
"circular-modules": "lerna exec -- madge --circular src",
Expand Down Expand Up @@ -69,7 +70,7 @@
"husky": {
"hooks": {
"pre-commit": "lint-staged",
"pre-push": "yarn circular-modules && yarn docs:build && yarn docs:commit"
"pre-push": "yarn circular-modules"
}
},
"lint-staged": {
Expand Down

0 comments on commit a2ac744

Please sign in to comment.