mirror of
https://github.com/Deutscher-Tischfussballbund/com_sportsmanager.git
synced 2026-06-10 06:27:52 +00:00
Merge pull request #94 from Deutscher-Tischfussballbund/sportsmanager2-dev
Dev to Stage PR
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
name-template: "Release $COMPLETE"
|
||||
tag-template: "v$COMPLETE"
|
||||
|
||||
exclude:
|
||||
pulls: true
|
||||
exclude-labels:
|
||||
- prod-merge
|
||||
- stage-merge
|
||||
|
||||
categories:
|
||||
- title: "Features"
|
||||
labels: ["feature", "enhancement"]
|
||||
- title: "Fixes"
|
||||
labels: ["bug"]
|
||||
- title: "Maintenance"
|
||||
labels: ["chore", "refactor"]
|
||||
|
||||
change-template: "- $TITLE [#$NUMBER]"
|
||||
|
||||
template: |
|
||||
# Release $COMPLETE
|
||||
|
||||
## Changes
|
||||
|
||||
$CHANGES
|
||||
@@ -1,8 +1,11 @@
|
||||
name-template: "Release $NEXT_PATCH_VERSION"
|
||||
tag-template: "v$NEXT_PATCH_VERSION"
|
||||
name-template: "Release $COMPLETE"
|
||||
tag-template: "v$COMPLETE"
|
||||
|
||||
exclude:
|
||||
pulls: true
|
||||
exclude-labels:
|
||||
- prod-merge
|
||||
- stage-merge
|
||||
|
||||
categories:
|
||||
- title: "Features"
|
||||
@@ -15,8 +18,6 @@ categories:
|
||||
change-template: "- $TITLE ([#$NUMBER]($URL))"
|
||||
|
||||
template: |
|
||||
# Release $NEXT_PATCH_VERSION
|
||||
|
||||
## Changes
|
||||
|
||||
$CHANGES
|
||||
@@ -0,0 +1,31 @@
|
||||
name: Auto-label PRs
|
||||
|
||||
on:
|
||||
pull_request:
|
||||
types: [opened, reopened, synchronize, edited]
|
||||
|
||||
jobs:
|
||||
label-stage-to-prod:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Label PRs
|
||||
uses: actions/github-script@v7
|
||||
with:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
script: |
|
||||
const base = context.payload.pull_request.base.ref;
|
||||
const head = context.payload.pull_request.head.ref;
|
||||
|
||||
if (base === 'sportsmanager2-prod' && head === 'sportsmanager2-stage') {
|
||||
await github.rest.issues.addLabels({
|
||||
...context.repo,
|
||||
issue_number: context.payload.pull_request.number,
|
||||
labels: ['prod-merge']
|
||||
});
|
||||
} else if (base === 'sportsmanager2-stage' && head === 'sportsmanager2-dev') {
|
||||
await github.rest.issues.addLabels({
|
||||
...context.repo,
|
||||
issue_number: context.payload.pull_request.number,
|
||||
labels: ['stage-merge']
|
||||
});
|
||||
}
|
||||
@@ -26,20 +26,32 @@ jobs:
|
||||
run: npm ci
|
||||
|
||||
- name: Generate release notes
|
||||
id: release_notes
|
||||
id: release_notes_extension
|
||||
uses: release-drafter/release-drafter@v6
|
||||
with:
|
||||
config-name: release-drafter.yml
|
||||
config-name: release-drafter_extension.yml
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Save release notes to file
|
||||
run: |
|
||||
echo "${{ steps.release_notes.outputs.body }}" > RELEASE_NOTES.md
|
||||
echo "${{ steps.release_notes_extension.outputs.body }}" > RELEASE_NOTES.md
|
||||
|
||||
- name: Run build script
|
||||
run: npm run release
|
||||
|
||||
- name: Generate release notes
|
||||
id: release_notes_github
|
||||
uses: release-drafter/release-drafter@v6
|
||||
with:
|
||||
config-name: release-drafter_github.yml
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Save release notes to file
|
||||
run: |
|
||||
echo "${{ steps.release_notes_github.outputs.body }}" > RELEASE_NOTES.md
|
||||
|
||||
- name: Create GitHub Release
|
||||
uses: softprops/action-gh-release@v2
|
||||
with:
|
||||
|
||||
Reference in New Issue
Block a user