Commit 4b67d25f authored by Vitaly Lipatov's avatar Vitaly Lipatov

fix write version in rpmrb/rpmgs

parent c05834f0
...@@ -190,6 +190,8 @@ fi ...@@ -190,6 +190,8 @@ fi
test -z "$LISTNAMES" && print_error test -z "$LISTNAMES" && print_error
[ -z "$GSSETRELEASE" ] || GSSKIPADDCHANGELOG=1
for i in $LISTNAMES for i in $LISTNAMES
do do
if [ -n "${i/*spec/}" ] ; then if [ -n "${i/*spec/}" ] ; then
...@@ -201,7 +203,7 @@ do ...@@ -201,7 +203,7 @@ do
CURVER=$(get_version $i) CURVER=$(get_version $i)
set_version $i $GSSETVERSION set_version $i $GSSETVERSION
if [ "$CURVER" != "$GSSETVERSION" ] ; then if [ "$CURVER" != "$GSSETVERSION" ] ; then
[ -n "$GSSETRELEASE" ] && GSSKIPADDCHANGELOG=1 || GSSETRELEASE=alt1 [ -n "$GSSETRELEASE" ] || GSSETRELEASE=alt1
set_release $i $GSSETRELEASE set_release $i $GSSETRELEASE
echo "Set new $GSSETVERSION-$GSSETRELEASE version for $i" echo "Set new $GSSETVERSION-$GSSETRELEASE version for $i"
else else
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
# load common functions, compatible with local and installed script # load common functions, compatible with local and installed script
. `dirname $0`/../share/eterbuild/functions/common . `dirname $0`/../share/eterbuild/functions/common
load_mod spec
REMOTE= REMOTE=
if [ "$1" = "-r" ] ; then if [ "$1" = "-r" ] ; then
...@@ -21,6 +22,8 @@ SPEC=$1 ...@@ -21,6 +22,8 @@ SPEC=$1
VER=$2 VER=$2
# need for rpmgs # need for rpmgs
GSSETRELEASE=$3 GSSETRELEASE=$3
test -n "$GSSETRELEASE" || GSSETRELEASE=alt1
export GSSETRELEASE
if [ "$1" = "-h" ]; then if [ "$1" = "-h" ]; then
echo "rpmrb spec [vermajor][.verminor] [rel] - update spec to vermajor.verminor version, build %rel release" echo "rpmrb spec [vermajor][.verminor] [rel] - update spec to vermajor.verminor version, build %rel release"
...@@ -29,9 +32,8 @@ fi ...@@ -29,9 +32,8 @@ fi
test -e "$SPEC" || fatal "use with spec" test -e "$SPEC" || fatal "use with spec"
test -n "$REL" || REL=alt1
rpmgs $SPEC $VER || fatal "Error with get source" rpmgs $SPEC $VER || fatal "Error with get source"
add_changelog_helper "- new version $VER (with rpmrb script)" $SPEC || echog "Changelog entry already exists" add_changelog_helper "- new version $(get_version $SPEC) (with rpmrb script)" $SPEC || echog "Changelog entry already exists"
rpmbsh $REMOTE -i $SPEC || fatal "Error with build in hasher" rpmbsh $REMOTE -i $SPEC || fatal "Error with build in hasher"
rpmbs -u $SPEC || fatal "Error with upload" rpmbs -u $SPEC || fatal "Error with upload"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment