Skip to content

Commit

Permalink
ci: use shared semantic-release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
seantrane committed Apr 11, 2023
1 parent f6887b6 commit c517f41
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 61 deletions.
65 changes: 9 additions & 56 deletions .github/workflows/delivery.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,62 +10,15 @@ concurrency:
cancel-in-progress: true

permissions:
contents: read
contents: write
id-token: write
issues: write
discussions: write
packages: write
pull-requests: write

jobs:
release:
name: Semantic Release
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
issues: write
discussions: write
packages: write
pull-requests: write
steps:
- name: Checkout
uses: actions/checkout@v3
with:
token: ${{ secrets.GH_PAT }}
fetch-depth: 0

# https://github.com/marketplace/actions/semantic-release-action#usage
- name: Semantic Release
uses: docker://ghcr.io/codfish/semantic-release-action:v2
id: semantic
env:
GITHUB_TOKEN: ${{ secrets.GH_PAT }}
with:
tag_format: 'v${version}'
additional_packages: |
[
'@semantic-release/changelog',
'@semantic-release/git'
]
plugins: |
[
'@semantic-release/commit-analyzer',
'@semantic-release/release-notes-generator',
['@semantic-release/changelog', {changelogTitle: '# CHANGELOG'}],
'@semantic-release/github',
'@semantic-release/git'
]
# specify default branches to add support for the `main` branch
# which semantic-release doesn't have as a default yet.
branches: |
[
'+([0-9])?(.{+([0-9]),x}).x',
'releases/+([0-9])?(.{+([0-9]),x}).x',
'main',
'next',
'next-major',
{
name: 'beta',
prerelease: true
},
{
name: 'alpha',
prerelease: true
}
]
uses: seantrane/engineering/.github/workflows/semantic-release.yml@main
secrets:
token: ${{ secrets.GH_PAT }}
3 changes: 1 addition & 2 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@ on:
push:
branches: [main]
paths:
- '.github/workflows/integration.yml'
- '.github/workflows/linter.yml'
- .github/workflows/integration.yml
workflow_dispatch:

concurrency:
Expand Down
5 changes: 2 additions & 3 deletions .github/workflows/maintenance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,8 @@ on:
push:
branches: [main]
paths:
- .github/labels.json
- .github/workflows/label-sync.yml
- .github/workflows/labels.yml
- labels.json
- .github/workflows/maintenance.yml
workflow_dispatch:

concurrency:
Expand Down

0 comments on commit c517f41

Please sign in to comment.