commit 3078cf2a1ef16d9553dbefd288229c3dc9b3f3f0 parent ccb1762caa7968480957b7696817d58ef74f3ae2 Author: Joris Hartog <jorishartog@hotmail.com> Date: Thu, 13 Aug 2026 07:08:52 +0200 Support re-deploying Diffstat:
| M | deployment.sh | | | 12 | +++++++++++- |
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/deployment.sh b/deployment.sh @@ -327,7 +327,17 @@ main() { [[ "$version" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]] || die "version must look like 0.2.48" ensure_clean_worktree - git rev-parse --verify "v${version}" >/dev/null 2>&1 && die "tag v${version} already exists" + + # Check if the tag already exists; if it does, only deploy + if git rev-parse --verify "v${version}" >/dev/null 2>&1; then + echo "Tag v${version} already exists; skipping build and deploying only" + if ! read -p "Are you sure you want to deploy v${version}? (y/N) " answer || [[ ! "$answer" =~ ^[Yy]$ ]]; then + echo "Aborting deployment" + exit 1 + fi + deploy_docker_image "$version" + exit 0 + fi update_versions "$version" commit_and_tag "$version"