mirror of
https://github.com/beetbox/beets.git
synced 2025-12-06 16:42:42 +01:00
Fixed an issue where the poetry-dynamic-versioning-plugin was not used in
release artifacts. Also adds a test_release workflow which allows to create the release distribution.
This commit is contained in:
parent
77842b72d7
commit
d01f960e4f
3 changed files with 46 additions and 6 deletions
43
.github/workflows/test_release.yaml
vendored
Normal file
43
.github/workflows/test_release.yaml
vendored
Normal file
|
|
@ -0,0 +1,43 @@
|
||||||
|
name: Make a Beets Release artifacts
|
||||||
|
|
||||||
|
on:
|
||||||
|
workflow_dispatch:
|
||||||
|
inputs:
|
||||||
|
version:
|
||||||
|
description: 'Version of the new release, just as a number with no prepended "v"'
|
||||||
|
required: true
|
||||||
|
|
||||||
|
env:
|
||||||
|
PYTHON_VERSION: 3.9
|
||||||
|
NEW_VERSION: ${{ inputs.version }}
|
||||||
|
NEW_TAG: v${{ inputs.version }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
increment-version:
|
||||||
|
name: Bump version, commit and create tag
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
- name: Install Python tools
|
||||||
|
uses: BrandonLWhite/pipx-install-action@v1.0.3
|
||||||
|
- uses: actions/setup-python@v5
|
||||||
|
with:
|
||||||
|
python-version: ${{ env.PYTHON_VERSION }}
|
||||||
|
cache: poetry
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: poetry install --with=release --extras=docs
|
||||||
|
|
||||||
|
- name: Bump project version
|
||||||
|
run: poe bump "${{ env.NEW_VERSION }}"
|
||||||
|
|
||||||
|
- name: Build a binary wheel and a source tarball
|
||||||
|
run: poe build
|
||||||
|
|
||||||
|
- name: Store the distribution packages
|
||||||
|
uses: actions/upload-artifact@v4
|
||||||
|
with:
|
||||||
|
name: python-package-distributions-test
|
||||||
|
path: dist/
|
||||||
|
|
@ -170,10 +170,6 @@ Other changes:
|
||||||
|
|
||||||
UpdateVersionCallable = Callable[[str, Version], str]
|
UpdateVersionCallable = Callable[[str, Version], str]
|
||||||
FILENAME_AND_UPDATE_TEXT: list[tuple[Path, UpdateVersionCallable]] = [
|
FILENAME_AND_UPDATE_TEXT: list[tuple[Path, UpdateVersionCallable]] = [
|
||||||
(
|
|
||||||
PYPROJECT,
|
|
||||||
lambda text, new: re.sub(r"(?<=\nversion = )[^\n]+", f'"{new}"', text),
|
|
||||||
),
|
|
||||||
(CHANGELOG, update_changelog),
|
(CHANGELOG, update_changelog),
|
||||||
(BASE / "docs" / "conf.py", update_docs_config),
|
(BASE / "docs" / "conf.py", update_docs_config),
|
||||||
]
|
]
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
[tool.poetry]
|
[tool.poetry]
|
||||||
name = "beets"
|
name = "beets"
|
||||||
version = "2.5.0"
|
version = "0.0.0"
|
||||||
description = "music tagger and library organizer"
|
description = "music tagger and library organizer"
|
||||||
authors = ["Adrian Sampson <adrian@radbox.org>"]
|
authors = ["Adrian Sampson <adrian@radbox.org>"]
|
||||||
maintainers = ["Serene-Arc"]
|
maintainers = ["Serene-Arc"]
|
||||||
|
|
@ -36,6 +36,7 @@ include = [ # extra files to include in the sdist
|
||||||
]
|
]
|
||||||
exclude = ["docs/_build", "docs/modd.conf", "docs/**/*.css"]
|
exclude = ["docs/_build", "docs/modd.conf", "docs/**/*.css"]
|
||||||
|
|
||||||
|
|
||||||
[tool.poetry.urls]
|
[tool.poetry.urls]
|
||||||
Changelog = "https://github.com/beetbox/beets/blob/master/docs/changelog.rst"
|
Changelog = "https://github.com/beetbox/beets/blob/master/docs/changelog.rst"
|
||||||
"Bug Tracker" = "https://github.com/beetbox/beets/issues"
|
"Bug Tracker" = "https://github.com/beetbox/beets/issues"
|
||||||
|
|
@ -173,7 +174,7 @@ build-backend = "poetry_dynamic_versioning.backend"
|
||||||
|
|
||||||
[tool.pipx-install]
|
[tool.pipx-install]
|
||||||
poethepoet = ">=0.26"
|
poethepoet = ">=0.26"
|
||||||
poetry = ">=1.8,<2"
|
poetry = { version = ">=1.8,<2", inject = {"poetry-dynamic-versioning[plugin]" = ">=1.9.1" }}
|
||||||
|
|
||||||
[tool.poe.tasks.build]
|
[tool.poe.tasks.build]
|
||||||
help = "Build the package"
|
help = "Build the package"
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue