From eda4815715fbbb58552b6c2f05c17d730e6f6528 Mon Sep 17 00:00:00 2001 From: Povilas Kanapickas Date: Tue, 7 Jan 2025 21:06:44 +0200 Subject: [PATCH] scripts: Add script to make new release Signed-off-by: Povilas Kanapickas --- scripts/make_release.sh | 24 ++++++++++++++++++------ scripts/make_release_upload.sh | 6 ++++++ 2 files changed, 24 insertions(+), 6 deletions(-) create mode 100755 scripts/make_release_upload.sh diff --git a/scripts/make_release.sh b/scripts/make_release.sh index 507bbee..a6c6cec 100755 --- a/scripts/make_release.sh +++ b/scripts/make_release.sh @@ -1,6 +1,18 @@ -#!/usr/bin/env bash -./scripts/uninstall.sh -./scripts/clean_up.sh -python3 setup.py register -python3 setup.py sdist bdist_wheel -twine upload dist/* +#!/bin/bash + +set -e + +if [ $# -ne 1 ]; then + echo "Usage: make_release.sh VERSION" + exit 1 +fi + +VERSION=$1 + +sed "s/__version__ = .*/__version__ = \"$VERSION\"/g" -i podman_compose.py +git add podman_compose.py +git commit -m "Release $VERSION" + +git tag "v$VERSION" -m "v$VERSION" -s + +git push ssh://github.com/containers/podman-compose main "v$VERSION" diff --git a/scripts/make_release_upload.sh b/scripts/make_release_upload.sh new file mode 100755 index 0000000..507bbee --- /dev/null +++ b/scripts/make_release_upload.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +./scripts/uninstall.sh +./scripts/clean_up.sh +python3 setup.py register +python3 setup.py sdist bdist_wheel +twine upload dist/*