Skip to content

Commit

Permalink
Merge pull request #9 from octo/release
Browse files Browse the repository at this point in the history
ci: Add a release workflow.
  • Loading branch information
octo authored Dec 17, 2024
2 parents 0fef4a5 + 9fdfbe7 commit 5dc098c
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:

jobs:
build:
name: '🏗️ Build'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down
33 changes: 33 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Release

on:
push:
branches:
- main

permissions:
contents: read

jobs:
release:
name: '🚀 Semantic Release'
runs-on: ubuntu-latest
permissions:
contents: write # to be able to publish a GitHub release
issues: write # to be able to comment on released issues
pull-requests: write # to be able to comment on released pull requests
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: "lts/*"
- name: Install dependencies
run: npm clean-install
- name: Release
#env:
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: npx semantic-release
20 changes: 20 additions & 0 deletions .releaserc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"branches" : [
"main"
],
"plugins" : [
[
"@semantic-release/commit-analyzer",
{
"preset" : "conventionalcommits"
}
],
[
"@semantic-release/release-notes-generator",
{
"preset" : "conventionalcommits"
}
],
"@semantic-release/github"
]
}

0 comments on commit 5dc098c

Please sign in to comment.