herrold wrote:

> package=Redhat70-ud
>         site=download.sourceforge.net
>         remote_dir=/pub/mirrors/redhat/redhat/updates/7.0
>         remote_user=anonymous
>         [EMAIL PROTECTED]
>         exclude_patt=(^|/)(\.mirror$|sparc|alpha)
>         compress_patt=
>         comment="Redhat70-ud"
>         local_dir=/home/ftp/pub/redhat/updates/7.0
>         make_bad_symlinks=true

how now do update the 2 cd's with the updates?
Has this changed any?
before we used something like

 #!/bin/bash

  RHVERSION=7.0

  LIST=/tmp/er3hd3w25
  CDDIR=/home/redhat/redhat-${RHVERSION}

  # Find all directories, and make sure they have +x permission
  find $CDDIR -type d -exec chmod -c 755 {} \;

  # Find all files that are executables, shell or perl scripts
  find $CDDIR -type f | file -f - | grep -v RPM \
     | egrep -i 'executable|perl|bourne|shell' | cut -f1 -d: > $LIST

  # Find shared libraries
  find $CDDIR -name \*.so >> $LIST

  # Make them executable
  while read file
  do
     if [ ! -x $file ] ; then
        chmod -c 755 $file
     fi
  done < $LIST

  /bin/rm $LIST

  exit 0
__________________________________________________

then we could

 RHVERSION=7.0
  ARCH=i386
  HOME=home/redhat

  CDDIR=/${HOME}/redhat-${RHVERSION}
  RPMDIR=${CDDIR}/${ARCH}/RedHat/RPMS
  UPDDIR=/${HOME}/updates/${ARCH}
  OLDDIR=${CDDIR}/old

  if [ ! -d $OLDDIR ] ; then
     echo making directory $OLDDIR
     mkdir $OLDDIR
  fi

  allow_null_glob_expansion=1

  for rpm in ${UPDDIR}/*.rpm ; do
    NAME=`rpm --queryformat "%{NAME}" -qp $rpm`
    unset OLDNAME
    for oldrpm in ${RPMDIR}/${NAME}*.rpm ; do
      if [ `rpm --queryformat "%{NAME}" -qp $oldrpm` = "$NAME" ]; then
        OLDNAME=$oldrpm;
        break
      fi
    done
    if [ -z "$OLDNAME" ]; then
      echo $NAME is new
      cp -pv $rpm $RPMDIR
    else
      if [ `basename $rpm` != `basename $OLDNAME` ]; then
        mv $OLDNAME $OLDDIR
        cp -pv $rpm $RPMDIR
      fi
    fi
  done

-- 
Kind regards

Kevin Waterson



_______________________________________________
Redhat-devel-list mailing list
[EMAIL PROTECTED]
https://listman.redhat.com/mailman/listinfo/redhat-devel-list

Reply via email to