ansible-collection-hetzner-.../scripts/version-sync.sh
Jonas L dd5ee78386
feat: replace ansible version with collection version in hcloud user agent (#291)
* feat: use collection version in hcloud user-agent

* chore: add version sync pre-commit hook

* chore: add changelog fragment
2023-08-09 11:34:12 +02:00

7 lines
268 B
Bash
Executable file

#!/usr/bin/env bash
# Sync the collection version variable based on the version in the galaxy.yml file.
galaxy_version="$(grep '^version:' galaxy.yml | cut -d ' ' -f 2)"
sed --in-place "s|version = .*|version = \"$galaxy_version\"|" plugins/module_utils/version.py