From 1ea397da1423b701befe85afcb6c11207cbca4ba Mon Sep 17 00:00:00 2001 From: Sebastian Tobie Date: Sat, 16 Mar 2024 10:39:59 +0100 Subject: [PATCH] improved the build process --- Makefile | 11 ++++++++--- changelogs/fragments/{0.1.1.yml => 0.4.3.yml} | 1 + galaxy.yml | 18 ++++++------------ src/ansible_module/__init__.py | 2 +- 4 files changed, 16 insertions(+), 16 deletions(-) rename changelogs/fragments/{0.1.1.yml => 0.4.3.yml} (67%) diff --git a/Makefile b/Makefile index f1c162e..0539b17 100644 --- a/Makefile +++ b/Makefile @@ -1,8 +1,13 @@ +VERSION := $(shell hatch version) + format: black . isort . -changelog: +version: + @yq --yaml-output-grammar-version 1.2 -i -y -s --arg 'version' "${VERSION}" '.[0] | (.version = $$version)' galaxy.yml + +changelog: version antsibull-changelog generate docs: format @@ -11,10 +16,10 @@ docs: format clean-dist: rm -rf dist -hatch-release: clean-dist +hatch-release: clean-dist version hatch build -galaxy-release: clean-dist changelog +galaxy-release: clean-dist changelog version ansible-galaxy collection build --output-path dist/galaxy upload: galaxy-release hatch-release diff --git a/changelogs/fragments/0.1.1.yml b/changelogs/fragments/0.4.3.yml similarity index 67% rename from changelogs/fragments/0.1.1.yml rename to changelogs/fragments/0.4.3.yml index 79e17c8..d42947a 100644 --- a/changelogs/fragments/0.1.1.yml +++ b/changelogs/fragments/0.4.3.yml @@ -3,3 +3,4 @@ minor_changes: - Added an type hint to the update_doc function - Added Type hint to the dictionary argument of the diff method - added an wrapper for fail_json and exit_json + - improved the version update, the version is now only in one place the source of truth diff --git a/galaxy.yml b/galaxy.yml index d9c11fa..908b75f 100644 --- a/galaxy.yml +++ b/galaxy.yml @@ -1,28 +1,22 @@ ---- namespace: sebastian name: base -version: 0.4.2 - +version: 0.4.3 readme: README.md - authors: - Sebastian Tobie -description: > - The base of my ansible collections. It provides the nessesary tools for my modules +description: The base of my ansible collections. It provides the nessesary tools for + my modules license_file: LICENSE.txt tags: - linux - systemd dependencies: {} - repository: https://gitea.sebastian-tobie.de/ansible/ansible-module.git -# documentation: https://gitea.sebastian-tobie.de/ansible/ansible-module homepage: https://gitea.sebastian-tobie.de/ansible/ansible-module issues: https://gitea.sebastian-tobie.de/ansible/ansible-module/issues - build_ignore: - - "*.gz" - - ".*" + - '*.gz' + - .* - Makefile - pyproject.toml - upload.sh @@ -30,5 +24,5 @@ build_ignore: - changelogs - docs - src - - "coverage.*" + - coverage.* - dist diff --git a/src/ansible_module/__init__.py b/src/ansible_module/__init__.py index df12433..f6b7e26 100644 --- a/src/ansible_module/__init__.py +++ b/src/ansible_module/__init__.py @@ -1 +1 @@ -__version__ = "0.4.2" +__version__ = "0.4.3"