diff options
-rwxr-xr-x | mockit | 20 | ||||
-rwxr-xr-x | mockrun | 3 |
2 files changed, 12 insertions, 11 deletions
@@ -2,9 +2,9 @@ if [ "$2" = "" ]; then echo -e "\nusage: $0 [ options ] SRPM distro [ min_ver [, max_ver [, mock_options ]]]\n" + echo -e "\t--redis store build command in redis queue" echo -e "\t--nobase | --scl only build SCL packages" - echo -e "\t--noscl | --base only build base packages" - echo -e "\t--redis store build command in redis queue\n" + echo -e "\t--noscl | --base only build base packages\n" exit 0 fi @@ -13,14 +13,6 @@ BUILD_BASE=1 BUILD_SCLS=1 REDIS=0 -if [ "$1" == "--nobase" -o "$1" == "--scl" ]; then - BUILD_BASE=0 - shift -fi -if [ "$1" == "--noscl" -o "$1" == "--base" ]; then - BUILD_SCLS=0 - shift -fi if [ "$1" == "--redis" ]; then CHECK=$(redis-cli ping) [ "$CHECK" = "PONG" ] || exit 1 @@ -28,6 +20,14 @@ if [ "$1" == "--redis" ]; then shift fi +if [ "$1" == "--nobase" -o "$1" == "--scl" ]; then + BUILD_BASE=0 + shift +elif [ "$1" == "--noscl" -o "$1" == "--base" ]; then + BUILD_SCLS=0 + shift +fi + SRPM=$1 DIST=$2 shift 2 @@ -33,7 +33,8 @@ do fi fi TXT="$(echo $CMD | sed -e 's/^.*-r //;s/ .*$//') " - echo -en "\r$(date +%X) ${TXT:0:10}" + RPM="$(echo $CMD | sed -e 's:\.rpm.*$:.rpm:;s:^.*/::')" + echo -en "\r$(date +%X) $RPM ${TXT:0:10}" $CMD --uniqueext=$PPID && echo " Ok." || echo " Error !" done |