Compare commits
58 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
bababb956e | ||
| 0e991a7f23 | |||
|
d2bcb57d53
|
|||
|
7bacf6deb6
|
|||
|
|
cadf44ab5b | ||
| e0491fb965 | |||
|
9c5e4d0510
|
|||
|
|
4a81ec56e6 | ||
| a316d6630b | |||
|
bf687305ef
|
|||
|
|
0bcf0200ab | ||
| 6dff0e0cfc | |||
|
474d92e180
|
|||
|
|
d00135b00c | ||
| 3dfaf8d74d | |||
|
73d406e18d
|
|||
|
|
b4b4aadb65 | ||
| b6af2370bb | |||
|
6fdfdbee31
|
|||
|
|
5c11d34c84 | ||
| 06e714b23b | |||
|
dd97c0d68a
|
|||
|
|
ec5a4f175a | ||
| a94cde06ac | |||
|
a0154f345c
|
|||
|
|
794b1ff5e1 | ||
| fc70ae2bdc | |||
|
6598e30a42
|
|||
|
b07928c8af
|
|||
|
|
3a47378dc1 | ||
|
09c240089f
|
|||
|
|
9c130ac1d0 | ||
|
|
721e817b20 | ||
|
4a51f0c8e1
|
|||
|
bacdf95171
|
|||
|
|
b9143544c4 | ||
|
4e59dfad54
|
|||
|
a0d0535044
|
|||
|
ea16d817e1
|
|||
|
9e2621cd60
|
|||
|
655b6c0df5
|
|||
|
605dc750e7
|
|||
|
78faddf56e
|
|||
| 2686d822cd | |||
|
a121e59f47
|
|||
|
|
bdc46d7f37 | ||
|
|
4259f49d94 | ||
|
95e2cdcdce
|
|||
|
|
55d0cb50e6 | ||
|
3424805d4e
|
|||
|
|
5c0fcbdb66 | ||
|
f35e19d44d
|
|||
|
|
ef54d663d2 | ||
|
2ab0dcd60b
|
|||
|
|
9a2b6eeafc | ||
|
4c6d4a7c6f
|
|||
| b3decbcd05 | |||
| 2aed04e150 |
@@ -1,22 +0,0 @@
|
|||||||
[tool.bumpversion]
|
|
||||||
current_version = "0.1.18"
|
|
||||||
parse = "(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)"
|
|
||||||
serialize = ["{major}.{minor}.{patch}"]
|
|
||||||
search = "{current_version}"
|
|
||||||
replace = "{new_version}"
|
|
||||||
regex = false
|
|
||||||
ignore_missing_version = false
|
|
||||||
ignore_missing_files = false
|
|
||||||
tag = true
|
|
||||||
sign_tags = false
|
|
||||||
tag_name = "v{new_version}"
|
|
||||||
tag_message = "Bump version: {current_version} → {new_version}"
|
|
||||||
allow_dirty = false
|
|
||||||
commit = true
|
|
||||||
message = "Bump version: {current_version} → {new_version}"
|
|
||||||
commit_args = ""
|
|
||||||
setup_hooks = []
|
|
||||||
pre_commit_hooks = []
|
|
||||||
post_commit_hooks = []
|
|
||||||
[[tool.bumpversion.files]]
|
|
||||||
filename = ".version"
|
|
||||||
36
.gitea/changelog-config.json
Normal file
36
.gitea/changelog-config.json
Normal file
@@ -0,0 +1,36 @@
|
|||||||
|
{
|
||||||
|
"categories": [
|
||||||
|
{
|
||||||
|
"title": "## 🚀 Features",
|
||||||
|
"labels": [
|
||||||
|
"add",
|
||||||
|
"Add",
|
||||||
|
"Kind/Feature"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "## 🐛 Fixes",
|
||||||
|
"labels": [
|
||||||
|
"fix",
|
||||||
|
"Fix"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"title": "## 🧪 Upgrade",
|
||||||
|
"labels": ["upgrade","Upgrade","Clean"]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"label_extractor": [
|
||||||
|
{
|
||||||
|
"pattern": "(\\w+) (.+)",
|
||||||
|
"target": "$1",
|
||||||
|
"on_property": "title"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"sort": "ASC",
|
||||||
|
"template": "${{CHANGELOG}}",
|
||||||
|
"pr_template": "- ${{TITLE}}\n - PR: #${{NUMBER}}",
|
||||||
|
"empty_template": "- no changes",
|
||||||
|
"max_pull_requests": 1000,
|
||||||
|
"max_back_track_time_days": 1000
|
||||||
|
}
|
||||||
@@ -1,10 +1,10 @@
|
|||||||
name: Bump version
|
name: Bump version
|
||||||
|
|
||||||
on:
|
|
||||||
|
|
||||||
on:
|
on:
|
||||||
release:
|
release:
|
||||||
types: [published]
|
types: [published]
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
@@ -18,6 +18,9 @@ jobs:
|
|||||||
curl -o git-chglog -L "https://github.com/git-chglog/git-chglog/releases/download/${CHGLOG_VERSION}/git-chglog_linux_amd64"
|
curl -o git-chglog -L "https://github.com/git-chglog/git-chglog/releases/download/${CHGLOG_VERSION}/git-chglog_linux_amd64"
|
||||||
chmod +x git-chglog
|
chmod +x git-chglog
|
||||||
|
|
||||||
|
- name: show structure
|
||||||
|
run: ls -la
|
||||||
|
|
||||||
- name: Generate CHANGELOG.md
|
- name: Generate CHANGELOG.md
|
||||||
id: generate
|
id: generate
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
@@ -1,10 +1,6 @@
|
|||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
inputs:
|
inputs:
|
||||||
release_notes:
|
|
||||||
description: Release notes (use \n for newlines)
|
|
||||||
type: string
|
|
||||||
required: false
|
|
||||||
github_release:
|
github_release:
|
||||||
description: 'Create Gitea Release'
|
description: 'Create Gitea Release'
|
||||||
default: true
|
default: true
|
||||||
@@ -28,6 +24,9 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 0 # Fetch full history
|
||||||
|
fetch-tags: true # Fetch all tags (refs/tags)
|
||||||
|
|
||||||
- name: Install uv
|
- name: Install uv
|
||||||
uses: astral-sh/setup-uv@v5
|
uses: astral-sh/setup-uv@v5
|
||||||
@@ -37,7 +36,7 @@ jobs:
|
|||||||
python-version-file: "pyproject.toml"
|
python-version-file: "pyproject.toml"
|
||||||
|
|
||||||
- name: Install the project
|
- name: Install the project
|
||||||
run: uv sync --locked --all-extras --dev
|
run: uv sync --all-extras --dev
|
||||||
- name: Set Git identity
|
- name: Set Git identity
|
||||||
run: |
|
run: |
|
||||||
git config user.name "Gitea CI"
|
git config user.name "Gitea CI"
|
||||||
@@ -52,31 +51,25 @@ jobs:
|
|||||||
echo "$(uv tool run bump-my-version show current_version)" >> $GITHUB_ENV
|
echo "$(uv tool run bump-my-version show current_version)" >> $GITHUB_ENV
|
||||||
echo "EOF" >> $GITHUB_ENV
|
echo "EOF" >> $GITHUB_ENV
|
||||||
- name: Check version
|
- name: Check version
|
||||||
run: echo ${{ env.VERSION }}
|
run: |
|
||||||
|
echo ${{ env.VERSION }}
|
||||||
|
cat pyproject.toml
|
||||||
- name: Push changes
|
- name: Push changes
|
||||||
uses: ad-m/github-push-action@master
|
uses: ad-m/github-push-action@master
|
||||||
with:
|
with:
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
branch: ${{ github.ref }}
|
branch: ${{ github.ref }}
|
||||||
|
|
||||||
- name: "Build Changelog"
|
- name: Build Changelog
|
||||||
id: build_changelog
|
id: build_changelog
|
||||||
uses: mikepenz/release-changelog-builder-action@v5.0.0
|
uses: https://github.com/mikepenz/release-changelog-builder-action@v5
|
||||||
|
with:
|
||||||
|
|
||||||
|
platform: "gitea"
|
||||||
|
baseURL: "http://gitea:3000"
|
||||||
|
configuration: ".gitea/changelog-config.json"
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITEA_TOKEN }}
|
||||||
|
|
||||||
- name: Add release notes to environment
|
|
||||||
id: add_release_notes
|
|
||||||
run: |
|
|
||||||
echo "RELEASE_NOTES<<EOF" >> $GITHUB_ENV
|
|
||||||
echo "${{ github.event.inputs.release_notes }}" >> $GITHUB_ENV
|
|
||||||
echo "EOF" >> $GITHUB_ENV
|
|
||||||
- name: Get the changelog
|
|
||||||
run: |
|
|
||||||
cat << "EOF"
|
|
||||||
${{ steps.changelog.outputs.changelog }}
|
|
||||||
EOF
|
|
||||||
echo ${{ steps.changelog.outputs.changelog }}
|
|
||||||
|
|
||||||
|
|
||||||
- name: Create release
|
- name: Create release
|
||||||
@@ -84,7 +77,7 @@ jobs:
|
|||||||
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: v${{ env.VERSION }}
|
||||||
release_name: Release ${{ env.VERSION }}
|
release_name: Release ${{ env.VERSION }}
|
||||||
body: ${{steps.build_changelog.outputs.changelog}}
|
body: ${{steps.build_changelog.outputs.changelog}}
|
||||||
draft: false
|
draft: false
|
||||||
|
|||||||
3
hello.py
3
hello.py
@@ -6,7 +6,8 @@ def main():
|
|||||||
def get_version():
|
def get_version():
|
||||||
with open(".version") as f:
|
with open(".version") as f:
|
||||||
return f.read().strip()
|
return f.read().strip()
|
||||||
|
print("Done")
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
main()
|
main()
|
||||||
|
print("This script has been executed successfully.")
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "workflowbumptester"
|
name = "workflowbumptester"
|
||||||
version = "0.1.0"
|
version = "1.0.10"
|
||||||
description = "Add your description here"
|
description = "Add your description here"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
requires-python = ">=3.13"
|
requires-python = ">=3.13"
|
||||||
@@ -8,3 +8,25 @@ dependencies = [
|
|||||||
"bump-my-version>=1.1.3",
|
"bump-my-version>=1.1.3",
|
||||||
"pyyaml>=6.0.2",
|
"pyyaml>=6.0.2",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
[tool.bumpversion]
|
||||||
|
current_version = "1.0.10"
|
||||||
|
parse = "(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)"
|
||||||
|
serialize = ["{major}.{minor}.{patch}"]
|
||||||
|
search = "{current_version}"
|
||||||
|
replace = "{new_version}"
|
||||||
|
regex = false
|
||||||
|
ignore_missing_version = false
|
||||||
|
ignore_missing_files = false
|
||||||
|
tag = true
|
||||||
|
sign_tags = false
|
||||||
|
tag_name = "v{new_version}"
|
||||||
|
tag_message = "Bump version: {current_version} → {new_version}"
|
||||||
|
allow_dirty = true
|
||||||
|
commit = true
|
||||||
|
message = "Bump version: {current_version} → {new_version}"
|
||||||
|
moveable_tags = []
|
||||||
|
commit_args = ""
|
||||||
|
setup_hooks = []
|
||||||
|
pre_commit_hooks = []
|
||||||
|
post_commit_hooks = []
|
||||||
|
|||||||
Reference in New Issue
Block a user