mirror of
https://github.com/containers/podman.git
synced 2025-08-06 11:32:07 +08:00

Also address review concerns in pr#18675. [NO NEW TESTS NEEDED] Co-authored-by: Chris Evich <cevich@redhat.com> Signed-off-by: Lokesh Mandvekar <lsm5@fedoraproject.org>
14 lines
394 B
Bash
14 lines
394 B
Bash
#!/usr/bin/env bash
|
|
|
|
# This script will update the Version field in the spec which is set to 0 by
|
|
# default. Useful for local manual rpm builds where the Version needs to be set
|
|
# correctly.
|
|
|
|
set -e
|
|
|
|
SPEC_FILE=$(pwd)/podman.spec
|
|
LATEST_TAG=$(git tag --sort=creatordate | tail -1)
|
|
LATEST_VERSION=$(echo $LATEST_TAG | sed -e 's/^v//')
|
|
|
|
sed -i "s/^Version:.*/Version: $LATEST_VERSION/" $SPEC_FILE
|