mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-04-11 12:24:13 +03:00
Fix version bumper
This commit is contained in:
parent
28054c3fde
commit
ec08475363
|
@ -25,7 +25,11 @@ jobs:
|
|||
id: latest_version
|
||||
shell: bash
|
||||
run: |
|
||||
LATEST_VERSION=$(git tag --sort=-creatordate | head -n 1)
|
||||
LATEST_VERSION="$(git tag --sort=-creatordate | head -n 1)"
|
||||
if [ -z "$LATEST_VERSION" ]; then
|
||||
echo "No tags found. Using version from __init__ file"
|
||||
LATEST_VERSION=$(grep -oP '__version__ = "\K[^"]+' {{cookiecutter.project_slug}}/__init__.py)
|
||||
fi
|
||||
echo "Found current version: ${LATEST_VERSION}"
|
||||
echo "version=${LATEST_VERSION}" >> "$GITHUB_OUTPUT"
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user