Commit 0da586dc authored by Vitaly Lipatov's avatar Vitaly Lipatov

rpmbph: fix passed args

parent 119bfe84
...@@ -15,7 +15,7 @@ load_mod repl rpm git buildsrpm spec ...@@ -15,7 +15,7 @@ load_mod repl rpm git buildsrpm spec
############################# #############################
# FIXME: CURRENTBRANCHNAME?? # FIXME: CURRENTBRANCHNAME??
Usage="Usage: $name [-r -u -U -n -i -m -v -q] [-$CURRENTBRANCHNAME] [-b REPONAME] spec..." Usage="Usage: $name [-r -u -U -n -i -m -v -q] [-b REPONAME] spec..."
function mygetopts() function mygetopts()
{ {
name=${0##*/} name=${0##*/}
...@@ -44,13 +44,13 @@ phelp() ...@@ -44,13 +44,13 @@ phelp()
# echog " -m - send result via e-mail" # echog " -m - send result via e-mail"
} }
# FIXME: has difference between PASSEDARGS=
UPLOADARG= while getopts :hnuaAfvqb: opt; do
while getopts :hnuvqb: opt; do
case $opt in case $opt in
h) phelp; exit 0 ;; h) phelp; exit 0 ;;
n) NOBUILD=1 ;; n) NOBUILD=1 ;;
u) UPLOADARG="-$opt" ;; u|a|A) PASSEDARGS="$PASSEDARGS -$opt" ;;
f) PASSEDARGS="$PASSEDARGS -$opt" ;;
v) VERBOSE=1 ;; v) VERBOSE=1 ;;
b) BINARYREPONAME=$OPTARG ;; b) BINARYREPONAME=$OPTARG ;;
q) QUIET=1 ;; q) QUIET=1 ;;
...@@ -64,8 +64,8 @@ if [ $# -gt 0 ]; then ...@@ -64,8 +64,8 @@ if [ $# -gt 0 ]; then
shift $((OPTIND - 1)) shift $((OPTIND - 1))
fi fi
# pass other options to RPM (exclude -v): # pass other options
LISTRPMARGS="$UPLOADARG $(drop_args "$*" v n q)" LISTRPMARGS="$PASSEDARGS $*"
} }
set_girar_host $1 && shift set_girar_host $1 && shift
...@@ -176,7 +176,7 @@ if [ "$PKGVENDOR" = "alt" ] && is_gear $SPECDIR ; then ...@@ -176,7 +176,7 @@ if [ "$PKGVENDOR" = "alt" ] && is_gear $SPECDIR ; then
cd - >/dev/null cd - >/dev/null
done done
docmd $BUILDCOMMAND $MENVARG $LISTRPMARGS $UPLOADARG $LISTNAMES docmd $BUILDCOMMAND -b $BINARYREPO $LISTRPMARGS $LISTNAMES
RET=$? RET=$?
for SPEC in $LISTNAMES ; do for SPEC in $LISTNAMES ; do
...@@ -212,7 +212,7 @@ for i in $LISTBUILT ; do ...@@ -212,7 +212,7 @@ for i in $LISTBUILT ; do
test -f "$SPECNAME" || fatal "Spec $SPECNAME is not found" test -f "$SPECNAME" || fatal "Spec $SPECNAME is not found"
docmd $ETERBUILDBIN/rpmbps -b $BINARYREPO $SPECNAME docmd $ETERBUILDBIN/rpmbps -b $BINARYREPO $SPECNAME
docmd $BUILDCOMMAND -b $BINARYREPO $LISTRPMARGS $UPLOADARG $SPECNAME || fatal "Can't build" docmd $BUILDCOMMAND -b $BINARYREPO $LISTRPMARGS $SPECNAME || fatal "Can't build"
uni_rpmrm $SPECNAME || true uni_rpmrm $SPECNAME || true
done done
......
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