Compare commits
54 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
5c983986bd
|
|||
|
e466a8eada
|
|||
|
2ee3630392
|
|||
|
d1a0746b3e
|
|||
| 9fbf7681ed | |||
|
387462cfc9
|
|||
|
|
8e35f02191 | ||
|
0f35839fb4
|
|||
|
|
a055276849 | ||
|
|
ce670c5539 | ||
|
7631ed6e7c
|
|||
|
cc5dc6141c
|
|||
|
|
a960641000 | ||
|
d8139a5193
|
|||
|
|
6ffc2f6a8f | ||
| 26e0da8f0b | |||
|
|
df1688dd75 | ||
|
a222e49a1d
|
|||
| 0ae5543fd2 | |||
| ac216e659e | |||
| ab233d51df | |||
| 95ce982379 | |||
| 2ae3968679 | |||
| 36abce649a | |||
| 045417ba6f | |||
| cd7e1f2af0 | |||
| 7b3f8ce11e | |||
|
|
592703b6cc | ||
| 173d480d5b | |||
|
|
0e2e20ea28 | ||
| 7796df45e5 | |||
|
|
ae8d2b01b3 | ||
| 3bf862d843 | |||
|
|
c00f2b91cc | ||
| 52a95c4860 | |||
|
|
4eab9159d4 | ||
| 6998b4f217 | |||
| 23640ed1a0 | |||
| 96efc6c312 | |||
| 96bb75653c | |||
| f1b7d2dab8 | |||
| fae5e23ba7 | |||
|
|
fde71d892c | ||
| 08e2ba4cf5 | |||
| f37372acfa | |||
| 00097b0301 | |||
| 78b76b057f | |||
| 9d04c05a40 | |||
| 0ebae7900b | |||
| a521361f7c | |||
| acf80c9e57 | |||
| 6f5957a52f | |||
| 43e9660c17 | |||
| 348ca30333 |
@@ -1,5 +1,5 @@
|
|||||||
[tool.bumpversion]
|
[tool.bumpversion]
|
||||||
current_version = "0.1.6"
|
current_version = "0.1.18"
|
||||||
parse = "(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)"
|
parse = "(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)"
|
||||||
serialize = ["{major}.{minor}.{patch}"]
|
serialize = ["{major}.{minor}.{patch}"]
|
||||||
search = "{current_version}"
|
search = "{current_version}"
|
||||||
|
|||||||
38
.chglog/CHANGELOG.tpl.md
Executable file
38
.chglog/CHANGELOG.tpl.md
Executable file
@@ -0,0 +1,38 @@
|
|||||||
|
{{ range .Versions }}
|
||||||
|
<a name="{{ .Tag.Name }}"></a>
|
||||||
|
## {{ if .Tag.Previous }}[{{ .Tag.Name }}]({{ $.Info.RepositoryURL }}/compare/{{ .Tag.Previous.Name }}...{{ .Tag.Name }}){{ else }}{{ .Tag.Name }}{{ end }} ({{ datetime "2006-01-02" .Tag.Date }})
|
||||||
|
|
||||||
|
{{ range .CommitGroups -}}
|
||||||
|
### {{ .Title }}
|
||||||
|
|
||||||
|
{{ range .Commits -}}
|
||||||
|
* {{ .Subject }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end -}}
|
||||||
|
|
||||||
|
{{- if .RevertCommits -}}
|
||||||
|
### Reverts
|
||||||
|
|
||||||
|
{{ range .RevertCommits -}}
|
||||||
|
* {{ .Revert.Header }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end -}}
|
||||||
|
|
||||||
|
{{- if .MergeCommits -}}
|
||||||
|
### Pull Requests
|
||||||
|
|
||||||
|
{{ range .MergeCommits -}}
|
||||||
|
* {{ .Header }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end -}}
|
||||||
|
|
||||||
|
{{- if .NoteGroups -}}
|
||||||
|
{{ range .NoteGroups -}}
|
||||||
|
### {{ .Title }}
|
||||||
|
|
||||||
|
{{ range .Notes }}
|
||||||
|
{{ .Body }}
|
||||||
|
{{ end }}
|
||||||
|
{{ end -}}
|
||||||
|
{{ end -}}
|
||||||
|
{{ end -}}
|
||||||
27
.chglog/config.yml
Executable file
27
.chglog/config.yml
Executable file
@@ -0,0 +1,27 @@
|
|||||||
|
style: github
|
||||||
|
template: CHANGELOG.tpl.md
|
||||||
|
info:
|
||||||
|
title: CHANGELOG
|
||||||
|
repository_url: https://git.theprivateserver.de/PHB/workflowbumptester
|
||||||
|
options:
|
||||||
|
commits:
|
||||||
|
# filters:
|
||||||
|
# Type:
|
||||||
|
# - feat
|
||||||
|
# - fix
|
||||||
|
# - perf
|
||||||
|
# - refactor
|
||||||
|
commit_groups:
|
||||||
|
# title_maps:
|
||||||
|
# feat: Features
|
||||||
|
# fix: Bug Fixes
|
||||||
|
# perf: Performance Improvements
|
||||||
|
# refactor: Code Refactoring
|
||||||
|
header:
|
||||||
|
pattern: "^(\\w*)\\:\\s(.*)$"
|
||||||
|
pattern_maps:
|
||||||
|
- Type
|
||||||
|
- Subject
|
||||||
|
notes:
|
||||||
|
keywords:
|
||||||
|
- BREAKING CHANGE
|
||||||
9
.gitea/release_notes.yml
Normal file
9
.gitea/release_notes.yml
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
changelog:
|
||||||
|
sections:
|
||||||
|
- title: ":star: New Features"
|
||||||
|
labels: ["Kind/Feature", "Kind/Enhancement"]
|
||||||
|
- title: ":lady_beetle: Bug Fixes"
|
||||||
|
labels: ["Kind/Bug", "Kind/Hotfix"]
|
||||||
|
issues:
|
||||||
|
exclude:
|
||||||
|
labels: ["wontfix", "question", "duplicate", "invalid"]
|
||||||
@@ -1,17 +1,10 @@
|
|||||||
name: Bump version
|
name: Bump version
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
|
||||||
inputs:
|
on:
|
||||||
bump-type:
|
release:
|
||||||
description: 'Bump type'
|
types: [published]
|
||||||
required: true
|
|
||||||
default: 'patch'
|
|
||||||
type: choice
|
|
||||||
options:
|
|
||||||
- major
|
|
||||||
- minor
|
|
||||||
- patch
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
@@ -19,20 +12,56 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Checkout the code
|
- name: Checkout the code
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
- name: Set Git identity
|
- name: Setup git-chglog
|
||||||
run: |
|
run: |
|
||||||
git config user.name "Gitea CI"
|
CHGLOG_VERSION="0.15.4"
|
||||||
git config user.email "ci@git.theprivateserver.de"
|
curl -o git-chglog -L "https://github.com/git-chglog/git-chglog/releases/download/${CHGLOG_VERSION}/git-chglog_linux_amd64"
|
||||||
- name: Bump version
|
chmod +x git-chglog
|
||||||
id: bump
|
|
||||||
uses: callowayproject/bump-my-version@master
|
|
||||||
env:
|
|
||||||
BUMPVERSION_TAG: "true"
|
|
||||||
with:
|
|
||||||
args: ${{ inputs.bump-type }}
|
|
||||||
github-token: ${{ secrets.TOKEN }}
|
|
||||||
|
|
||||||
- name: Check
|
- name: Generate CHANGELOG.md
|
||||||
if: steps.bump.outputs.bumped == 'true'
|
id: generate
|
||||||
run: |
|
run: |
|
||||||
echo "Version was bumped from ${{ steps.bump.outputs.previous-version }} to ${{ steps.bump.outputs.current-version }}!"
|
rm -f CHANGELOG.md
|
||||||
|
./git-chglog -o CHANGELOG.md
|
||||||
|
if git diff --quiet CHANGELOG.md; then
|
||||||
|
echo "changes=false" >> $GITHUB_OUTPUT
|
||||||
|
else
|
||||||
|
echo "changes=true" >> $GITHUB_OUTPUT
|
||||||
|
fi
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
- name: Cleanup
|
||||||
|
run: rm git-chglog
|
||||||
|
if: always()
|
||||||
|
|
||||||
|
- name: Create Pull Request
|
||||||
|
if: steps.generate.outputs.changes == 'true'
|
||||||
|
uses: peter-evans/create-pull-request@v4
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
commit-message: "chore: update CHANGELOG.md"
|
||||||
|
title: "📝 Update Changelog"
|
||||||
|
body: |
|
||||||
|
This PR updates the CHANGELOG.md to include all releases.
|
||||||
|
- Generated using git-chglog
|
||||||
|
- Triggered by: ${{ github.event_name }}
|
||||||
|
- Auto-merge enabled
|
||||||
|
branch: update-changelog-${{ github.run_id }}
|
||||||
|
base: main
|
||||||
|
delete-branch: true
|
||||||
|
labels: documentation, automated-pr
|
||||||
|
|
||||||
|
- name: Enable Auto-merge
|
||||||
|
if: steps.generate.outputs.changes == 'true'
|
||||||
|
uses: pascalgn/automerge-action@v0.15.0
|
||||||
|
with:
|
||||||
|
mergeMethod: squash
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
pullRequestNumber: ${{ steps.create-pull-request.outputs.pullRequestNumber }}
|
||||||
|
commitMessage: "chore: update CHANGELOG.md"
|
||||||
|
title: "📝 Update Changelog"
|
||||||
|
body: |
|
||||||
|
This PR updates the CHANGELOG.md to include all releases.
|
||||||
|
- Generated using git-chglog
|
||||||
|
- Triggered by: ${{ github.event_name }}
|
||||||
@@ -11,3 +11,13 @@ jobs:
|
|||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
- name: echo name
|
- name: echo name
|
||||||
run: echo ${{ github.event.repository.owner.login }}
|
run: echo ${{ github.event.repository.owner.login }}
|
||||||
|
- name: Get milestone from tag
|
||||||
|
id: milestone-from-tag
|
||||||
|
run: |
|
||||||
|
milestone=0.1.7
|
||||||
|
echo "milestone=$milestone" >> $GITHUB_OUTPUT
|
||||||
|
echo $milestone
|
||||||
|
- name: Generate Changelog
|
||||||
|
uses: spring-io/github-changelog-generator@v0.0.12
|
||||||
|
with:
|
||||||
|
milestone: ${{ steps.milestone-from-tag.outputs.milestone }}
|
||||||
@@ -19,9 +19,12 @@ on:
|
|||||||
- 'minor'
|
- 'minor'
|
||||||
- 'patch'
|
- 'patch'
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
release:
|
release:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
if: "contains(github.event.head_commit.message, 'release') || github.event_name == 'workflow_dispatch'"
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
@@ -55,62 +58,37 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
branch: ${{ github.ref }}
|
branch: ${{ github.ref }}
|
||||||
- name: Build Changelog
|
|
||||||
uses: https://github.com/mikepenz/release-changelog-builder-action@v5
|
- name: "Build Changelog"
|
||||||
with:
|
id: build_changelog
|
||||||
platform: "gitea" # gitea or GitHub, default is GitHub
|
uses: mikepenz/release-changelog-builder-action@v5.0.0
|
||||||
mode: "COMMIT"
|
env:
|
||||||
configurationJson: |
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
{
|
|
||||||
"template": "#{{CHANGELOG}}",
|
- name: Add release notes to environment
|
||||||
"categories": [
|
id: add_release_notes
|
||||||
{
|
run: |
|
||||||
"title": "## Feature",
|
echo "RELEASE_NOTES<<EOF" >> $GITHUB_ENV
|
||||||
"labels": ["feat", "feature"]
|
echo "${{ github.event.inputs.release_notes }}" >> $GITHUB_ENV
|
||||||
},
|
echo "EOF" >> $GITHUB_ENV
|
||||||
{
|
- name: Get the changelog
|
||||||
"title": "## Fix",
|
run: |
|
||||||
"labels": ["fix", "bug"]
|
cat << "EOF"
|
||||||
},
|
${{ steps.changelog.outputs.changelog }}
|
||||||
{
|
EOF
|
||||||
"title": "## Other",
|
echo ${{ steps.changelog.outputs.changelog }}
|
||||||
"labels": []
|
|
||||||
}
|
|
||||||
],
|
- name: Create release
|
||||||
"label_extractor": [
|
id: create_release
|
||||||
{
|
|
||||||
"pattern": "^(build|chore|ci|docs|feat|fix|perf|refactor|revert|style|test){1}(\\([\\w\\-\\.]+\\))?(!)?: ([\\w ])+([\\s\\S]*)",
|
|
||||||
"on_property": "title",
|
|
||||||
"target": "$1"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
token: ${{ secrets.TOKEN }}
|
|
||||||
owner: WorldTeacher
|
|
||||||
- name: create Release
|
|
||||||
if: ${{ github.event.inputs.github_release == 'true' }}
|
if: ${{ github.event.inputs.github_release == 'true' }}
|
||||||
uses: softprops/action-gh-release@master
|
uses: softprops/action-gh-release@master
|
||||||
with:
|
with:
|
||||||
tag_name: ${{ env.VERSION }}
|
tag_name: ${{ env.VERSION }}
|
||||||
release_name: Release ${{ env.VERSION }}
|
release_name: Release ${{ env.VERSION }}
|
||||||
body: ${{ steps.changelog.outputs.changelog }}
|
body: ${{steps.build_changelog.outputs.changelog}}
|
||||||
|
draft: false
|
||||||
# - name: Add release notes to environment
|
prerelease: false
|
||||||
# id: add_release_notes
|
make_latest: true
|
||||||
# run: |
|
env:
|
||||||
# echo "RELEASE_NOTES<<EOF" >> $GITHUB_ENV
|
GITHUB_TOKEN: ${{ secrets.TOKEN }}
|
||||||
# echo "${{ github.event.inputs.release_notes }}" >> $GITHUB_ENV
|
|
||||||
# echo "EOF" >> $GITHUB_ENV
|
|
||||||
# - name: Create release
|
|
||||||
# id: create_release
|
|
||||||
# if: ${{ github.event.inputs.github_release == 'true' }}
|
|
||||||
# uses: softprops/action-gh-release@master
|
|
||||||
# with:
|
|
||||||
# tag_name: ${{ env.VERSION }}
|
|
||||||
# release_name: Release ${{ env.VERSION }}
|
|
||||||
# body: ${{ env.RELEASE_NOTES }}
|
|
||||||
# draft: false
|
|
||||||
# prerelease: false
|
|
||||||
# make_latest: true
|
|
||||||
# env:
|
|
||||||
# GITHUB_TOKEN: ${{ secrets.TOKEN }}
|
|
||||||
|
|||||||
33
.gitea/workflows/release_notes.yml
Normal file
33
.gitea/workflows/release_notes.yml
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
on:
|
||||||
|
milestone:
|
||||||
|
types: [closed]
|
||||||
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
milestoneId:
|
||||||
|
description: 'Milestone ID'
|
||||||
|
required: true
|
||||||
|
default: '1'
|
||||||
|
name: Milestone Closure
|
||||||
|
jobs:
|
||||||
|
create-release-notes:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@master
|
||||||
|
- name: Generate changelog
|
||||||
|
id: changelog
|
||||||
|
uses: metcalfc/changelog-generator@3f82cef08fe5dcf57c591fe165e70e1d5032e15a # was: metcalfc/changelog-generator@v4.6.2
|
||||||
|
with:
|
||||||
|
myToken: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
- name: Generate Sprint-io Changelog
|
||||||
|
uses: spring-io/github-changelog-generator@v0.0.12
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
milestone: ${{ github.event.inputs.milestoneId }}
|
||||||
|
- name: Create Release
|
||||||
|
id: create_release
|
||||||
|
uses: ncipollo/release-action@440c8c1cb0ed28b9f43e4d1d670870f059653174 # was: ncipollo/release-action@v1
|
||||||
|
with:
|
||||||
|
tag: ${{ github.ref }}
|
||||||
|
name: Release ${{ github.ref_name }}
|
||||||
|
body: ${{ steps.changelog.outputs.changelog }}
|
||||||
|
token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
Reference in New Issue
Block a user