Skip to content

Commit

Permalink
feat: Add semantic release
Browse files Browse the repository at this point in the history
  • Loading branch information
Josh Larson committed Nov 20, 2020
1 parent fbc1c18 commit 6d56e60
Show file tree
Hide file tree
Showing 3 changed files with 226 additions and 1 deletion.
6 changes: 6 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,12 @@ jobs:
yarn test
env:
CI: true
- name: yarn build
run: yarn build
- name: release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: npx semantic-release
- name: Notify slack success
if: env.SLACK_BOT_TOKEN
env:
Expand Down
38 changes: 38 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
"devDependencies": {
"@babel/core": "^7.6.4",
"@babel/preset-env": "^7.6.3",
"@semantic-release/changelog": "^5.0.1",
"@semantic-release/git": "^9.0.0",
"@zeit/ncc": "^0.20.5",
"babel-jest": "^24.9.0",
"husky": "^3.0.9",
Expand All @@ -26,5 +28,41 @@
"hooks": {
"pre-commit": "pretty-quick --staged"
}
},
"release": {
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
"@semantic-release/changelog",
[
"@semantic-release/npm",
{
"npmPublish": false
}
],
"@semantic-release/github",
[
"@semantic-release/git",
{
"assets": [
"CHANGELOG.md",
"package.json",
"dist"
]
}
]
],
"branches": [
"main",
"+([0-9])?(.{+([0-9]),x}).x",
{
"name": "beta",
"prerelease": true
},
{
"name": "alpha",
"prerelease": true
}
]
}
}
Loading

0 comments on commit 6d56e60

Please sign in to comment.