Skip to content

Commit

Permalink
ci(release): defined a github workflow to release with semantic-relea…
Browse files Browse the repository at this point in the history
  • Loading branch information
travi authored and ryansonshine committed Aug 16, 2022
1 parent 475354a commit 5c5babc
Showing 1 changed file with 9 additions and 20 deletions.
29 changes: 9 additions & 20 deletions .github/workflows/release.yml
@@ -1,31 +1,20 @@
name: Release
on:
"on":
push:
branches:
- main
- master
jobs:
release:
name: 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@v2
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
cache: npm
node-version: lts/*
- name: Git Config
run: git config --global user.email "you@example.com" && git config --global user.name "Your Name"
- name: Install dependencies
run: npm ci
- name: Test
run: npm test
- name: Build
run: npm run build
- name: Release
- run: npm clean-install
- run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: npx semantic-release
NPM_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}

0 comments on commit 5c5babc

Please sign in to comment.