Commit 0007f66b authored by Vitaly Lipatov's avatar Vitaly Lipatov

fix rpmgp after refactoring

parent dd87316c
...@@ -92,7 +92,7 @@ check_name() ...@@ -92,7 +92,7 @@ check_name()
echo "Error: missed package param" echo "Error: missed package param"
exit 1 exit 1
fi fi
NLIST=`cat $LIST | grep -i $1` NLIST=`cat $LIST | grep -i "$1"`
# if [ `cat $LIST | list_filter | grep -i $1 | wc -l` -gt 1 ] ; then # if [ `cat $LIST | list_filter | grep -i $1 | wc -l` -gt 1 ] ; then
#echo "Please type a full name of the package" #echo "Please type a full name of the package"
# print_list $NLIST # print_list $NLIST
...@@ -115,7 +115,7 @@ check_system() ...@@ -115,7 +115,7 @@ check_system()
#echo "Check for $SYSTEM" #echo "Check for $SYSTEM"
get_list $IDX get_list $IDX
#ls -l $LIST #ls -l $LIST
check_name $NAME check_name $PKGNAME
if [ "$DOWNLOADALL" ] ; then if [ "$DOWNLOADALL" ] ; then
for i in $NLIST ; do for i in $NLIST ; do
download_url $URL/$i download_url $URL/$i
...@@ -188,9 +188,12 @@ done ...@@ -188,9 +188,12 @@ done
# FIXME: параметры передаются и дальше (например, -i, -b) # FIXME: параметры передаются и дальше (например, -i, -b)
# remove args that were options # remove args that were options
if [ $# -gt 0 ]; then #if [ $# -gt 0 ]; then
shift $((OPTIND - 1)) # shift $((OPTIND - 1))
fi #fi
# remove args that were options
shift $((OPTIND - 1))
# pass other options to RPM: # pass other options to RPM:
LISTRPMARGS=$@ LISTRPMARGS=$@
...@@ -328,27 +331,26 @@ fi ...@@ -328,27 +331,26 @@ fi
# FIXME: use mygetopts (LISTRPMARGS and so) # FIXME: use mygetopts (LISTRPMARGS and so)
if [ -n "$2" ] && [ "$1" = "all" ] ; then #if [ -n "$2" ] && [ "$1" = "all" ] ; then
shift # shift
ALLSYSTEM=1 # ALLSYSTEM=1
fi #fi
# DISABLED. TODO: REWRITE
# Check concrete system # Check concrete system
# two params: system, package # two params: system, package
if [ -n "$2" ] ; then if [ -n "$2" ] && false ; then
NAME=$2 PKGNAME=$2
load_systems_list load_systems_list
IDX=`get_system_idx "$1"` IDX=`get_system_idx "$1"`
if [ -n "$IDX" ] ; then if [ -n "$IDX" ] ; then
check_system $IDX check_system $IDX
print_list $NLIST print_list $NLIST
else else
#fatal "Unknown system '$1', use rpmgp -s for get list" fatal "Unknown system '$1', use rpmgp -s for get list"
NAME= #PKGNAME=
fi fi
exit 0 exit 0
else
NAME=$1
fi fi
# Check all systems # Check all systems
......
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