SPECS: relup.sh - support %{rel} too
qboosh
qboosh at pld-linux.org
Wed Dec 26 02:36:32 CET 2007
Author: qboosh Date: Wed Dec 26 01:36:32 2007 GMT
Module: SPECS Tag: HEAD
---- Log message:
- support %{rel} too
---- Files affected:
SPECS:
relup.sh (1.16 -> 1.17)
---- Diffs:
================================================================
Index: SPECS/relup.sh
diff -u SPECS/relup.sh:1.16 SPECS/relup.sh:1.17
--- SPECS/relup.sh:1.16 Mon Dec 3 00:36:51 2007
+++ SPECS/relup.sh Wed Dec 26 02:36:26 2007
@@ -34,7 +34,7 @@
get_release() {
local specfile="$1"
- rel=$(awk '/^%define[ ]*_rel[ ]/{print $NF}' $specfile)
+ rel=$(awk '/^%define[ ]+_?rel[ ]+/{print $NF}' $specfile)
if [ -z "$rel" ]; then
dump=$(get_dump "$specfile")
rel=$(echo "$dump" | awk '/PACKAGE_RELEASE/{print $NF; exit}')
@@ -47,7 +47,7 @@
local rel="$2"
local newrel="$3"
sed -i -e "
- s/^\(%define[ \t]\+_rel[ \t]\+\)$rel\$/\1$newrel/
+ s/^\(%define[ \t]\+_\?rel[ \t]\+\)$rel\$/\1$newrel/
s/^\(Release:[ \t]\+\)$rel\$/\1$newrel/
" $specfile
}
================================================================
---- CVS-web:
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/SPECS/relup.sh?r1=1.16&r2=1.17&f=u
More information about the pld-cvs-commit
mailing list