X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?p=picodrive.git;a=blobdiff_plain;f=platform%2Fpandora%2Fmake_pxml.sh;h=2fcf8334bc303c6d762baeea6b8119d4d2923cfa;hp=3fd03a23c5c259ed4b2b45dfcf376ba16ce57ff5;hb=ee5d41a1edcfd0ac2fece688df2d476628a8b333;hpb=35f2b65ef708e7afc922ceda8d00b716de289610 diff --git a/platform/pandora/make_pxml.sh b/platform/pandora/make_pxml.sh index 3fd03a2..2fcf833 100755 --- a/platform/pandora/make_pxml.sh +++ b/platform/pandora/make_pxml.sh @@ -8,10 +8,13 @@ major=`head -n 1 $verfile | sed 's/.*"\([0-9]*\)\.\([0-9]*\).*/\1/g'` minor=`head -n 1 $verfile | sed 's/.*"\([0-9]*\)\.\([0-9]*\).*/\2/g'` # lame, I know.. build=`git describe HEAD | grep -- - | sed -e 's/.*\-\(.*\)\-.*/\1/'` +test -n "$build" && build_post="-$build" test -n "$build" || build=0 trap "rm -f $2" ERR -sed 's/@major@/'$major'/' "$1" > "$2" -sed -i 's/@minor@/'$minor'/' "$2" -sed -i 's/@build@/'$build'/' "$2" +sed -e 's/@major@/'$major'/' \ + -e 's/@minor@/'$minor'/' \ + -e 's/@build@/'$build'/' \ + -e 's/@build_post@/'$build_post'/' \ + "$1" > "$2"