Skip to content

Commit

Permalink
build: update release workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
mob-sakai committed Nov 20, 2023
1 parent 563142f commit b0ca7da
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 4 deletions.
8 changes: 7 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ jobs:
channel: ${{ steps.release.outputs.new_release_channel }}
released: ${{ steps.release.outputs.new_release_published }}
tag: ${{ steps.release.outputs.new_release_git_tag }}
version: ${{ steps.release.outputs.new_release_version }}
notes: ${{ steps.release.outputs.new_release_notes }}
steps:
- name: 🚚 Checkout (${{ github.ref_name }})
uses: actions/checkout@v4
Expand All @@ -39,8 +41,10 @@ jobs:

- run: |
echo "🔖 New release published: '${{ steps.release.outputs.new_release_published }}'" | tee -a $GITHUB_STEP_SUMMARY
echo "🔖 New release version: '${{ steps.release.outputs.new_release_version }}'" | tee -a $GITHUB_STEP_SUMMARY
echo "🔖 New release channel: '${{ steps.release.outputs.new_release_channel }}'" | tee -a $GITHUB_STEP_SUMMARY
echo "🔖 New release git tag: '${{ steps.release.outputs.new_release_git_tag }}'" | tee -a $GITHUB_STEP_SUMMARY
echo '${{ steps.release.outputs.new_release_notes }}' | tee -a $GITHUB_STEP_SUMMARY
merge-to-develop:
name: 🔀 Merge to develop
Expand All @@ -60,7 +64,9 @@ jobs:
uses: ./.github/workflows/snapshot.yml
with:
from: ${{ needs.release.outputs.tag }}
to: main_sandbox
to: main
path: Packages/src
tag: ${{ needs.release.outputs.version }}
message: "chore(release): ${{ needs.release.outputs.version }} [skip ci]"
permissions:
contents: write
14 changes: 13 additions & 1 deletion .github/workflows/snapshot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ on:
required: true
path:
required: true
message:
required: true
tag:
required: true
workflow_call:
inputs:
from:
Expand All @@ -20,6 +24,12 @@ on:
path:
required: true
type: string
message:
required: true
type: string
tag:
required: true
type: string

jobs:
merge:
Expand Down Expand Up @@ -51,5 +61,7 @@ jobs:
git config --local user.name "github-actions[bot]"
git add -A
git commit -m "📷 Snapshot '${{ inputs.path }}' from '${{ inputs.from }}' to '${{ inputs.to }}'"
git commit -m "${{ inputs.message }}"
git tag ${{ inputs.tag }}
git push origin ${{ inputs.to }}
git push origin ${{ inputs.tag }}
3 changes: 1 addition & 2 deletions Packages/src/.releaserc.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
{
"branches": [
"+([0-9])?(.{+([0-9]),x}).x",
"master",
"release",
"main",
{
"name": "preview",
"prerelease": true
}
],
"tagFormat": "${version}",
"plugins": [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
Expand Down

0 comments on commit b0ca7da

Please sign in to comment.