Skip to content

Commit

Permalink
Merge pull request #3 from BitGo/semantic-release
Browse files Browse the repository at this point in the history
feat: add semantic release versioning
  • Loading branch information
lcovar authored Sep 15, 2023
2 parents 992c0ff + 0f0fd6d commit 27ab8ba
Show file tree
Hide file tree
Showing 4 changed files with 17,579 additions and 3 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/main_ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: Run Tests

on:
push:
branches:
- master
- '!release-do-not-use'
pull_request:

permissions:
contents: write

jobs:
unit:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579 # v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3
with:
node-version: 18
registry-url: https://registry.npmjs.org/
cache: 'npm'
- run: npm i
- run: npm run unit

release:
if: github.repository_owner == 'BitGo' && github.event_name == 'push' && github.ref_name == 'master'
runs-on: ubuntu-latest
needs:
- unit
steps:
- uses: actions/checkout@ec3a7ce113134d7a93b817d10a8272cb61118579 # v2
- uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3
with:
node-version: 18
cache: 'npm'
- run: npm ci
- run: ./node_modules/.bin/semantic-release
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
21 changes: 21 additions & 0 deletions .releaserc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"branches": [
"release-do-not-use",
{
"name": "master",
"prerelease": true,
"channel": "rc"
}
],
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/npm",
[
"@semantic-release/github",
{
"failComment": false
}
]
]
}
Loading

0 comments on commit 27ab8ba

Please sign in to comment.