Skip to content

Commit

Permalink
chore: Update release-please
Browse files Browse the repository at this point in the history
  • Loading branch information
Jason3S committed Sep 4, 2023
1 parent bf20404 commit b9e9ffd
Show file tree
Hide file tree
Showing 2 changed files with 97 additions and 6 deletions.
45 changes: 39 additions & 6 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,51 @@
name: ' 🚀 release-please'

on:
workflow_dispatch:
push:
branches:
- main
workflow_dispatch:

name: ' 🚀 release-please'
permissions:
actions: read
checks: write
contents: write
issues: read
packages: write
pull-requests: write
repository-projects: read
statuses: read

jobs:
release-please:
runs-on: ubuntu-latest
outputs:
release_created: ${{ steps.release.outputs.release_created }}
steps:
- uses: google-github-actions/release-please-action@v3
id: release
with:
command: manifest
release-type: ''
release-type: node

# The logic below handles the tag logic:
- uses: actions/checkout@v3
if: ${{ steps.release.outputs.release_created }}

- name: tag major and minor versions
if: ${{ steps.release.outputs.release_created }}
run: |
git config user.name github-actions[bot]
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
git remote add gh-token "https://${{ secrets.GITHUB_TOKEN }}@github.com/streetsidesoftware/cspell-action.git"
git tag -d latest || true
git tag -d v${{ steps.release.outputs.major }} || true
git tag -d v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} || true
git push origin :latest || true
git push origin :v${{ steps.release.outputs.major }} || true
git push origin :v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} || true
git tag -a latest -m "Release latest"
git tag -a v${{ steps.release.outputs.major }} -m "Release v${{ steps.release.outputs.major }}"
git tag -a v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }} -m "Release v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}"
git push origin latest
git push origin v${{ steps.release.outputs.major }}
git push origin v${{ steps.release.outputs.major }}.${{ steps.release.outputs.minor }}
# cspell:ignore noreply
58 changes: 58 additions & 0 deletions release-please-config.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,62 @@
{
"changelog-sections": [
{
"type": "feat",
"section": "Features",
"hidden": false
},
{
"type": "feature",
"section": "Features"
},
{
"type": "fix",
"section": "Updates and Bug Fixes",
"hidden": false
},
{
"type": "perf",
"section": "Performance Improvements"
},
{
"type": "ci",
"section": "Continuous Integration",
"hidden": true
},
{
"type": "chore",
"section": "Miscellaneous",
"hidden": true
},
{
"type": "revert",
"section": "Reverts"
},
{
"type": "docs",
"section": "Documentation"
},
{
"type": "style",
"section": "Styles",
"hidden": true
},
{
"type": "refactor",
"section": "Code Refactoring",
"hidden": false
},
{
"type": "test",
"section": "Tests",
"hidden": true
},
{
"type": "build",
"section": "Build System",
"hidden": true
}
],
"packages": {
".": {
"releaseType": "node",
Expand Down

0 comments on commit b9e9ffd

Please sign in to comment.