Skip to content
This repository has been archived by the owner on Dec 30, 2021. It is now read-only.

Commit

Permalink
ci: add semantic-release to Github Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
spotify-kai committed Mar 9, 2021
1 parent 271be57 commit 70bc1f7
Show file tree
Hide file tree
Showing 4 changed files with 17,735 additions and 6,287 deletions.
33 changes: 33 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Release

on:
push:
branches: [$default-branch]

jobs:
release:
name: Release
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: 14
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build --if-present
- name: Run linters
run: npm run lint
- name: Run tests
run: npm test
- name: Release
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: npx semantic-release
16 changes: 12 additions & 4 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,21 @@ jobs:
node-version: [12.x, 14.x, 15.x]

steps:
- uses: actions/checkout@v2
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm run build --if-present
- run: npm test
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build --if-present
- name: Run linters
run: npm run lint
- name: Run tests
run: npm test
- name: Release Dry-run
run: npx semantic-release --dry-run
Loading

0 comments on commit 70bc1f7

Please sign in to comment.