home *** CD-ROM | disk | FTP | other *** search
/ Freelog 2 / Freelog002.iso / slakware / y1 / maketag < prev    next >
Text File  |  1999-02-08  |  1KB  |  47 lines

  1. #!/bin/sh
  2. #item   ####description                                      ###on off ###
  3. TMP=/var/log/setup/tmp
  4. if [ ! -d $TMP ]; then
  5.   mkdir -p $TMP
  6. fi
  7. add() {
  8.   for package in $* ; do
  9.     echo "$package: ADD" >> $TMP/SeTnewtag
  10.   done
  11. }
  12. skip() {
  13.   for package in $* ; do
  14.     echo "$package: SKP" >> $TMP/SeTnewtag
  15.   done
  16. }
  17. cat /dev/null > $TMP/SeTnewtag
  18. dialog --title "SELECTING PACKAGES FROM SERIES Y (GAMES)" \
  19.        --checklist "Please select the packages you wish to install \
  20. from series Y. Use the \
  21. UP/DOWN keys to scroll through the list, and the SPACE key to select \
  22. the packages you wish to install. \
  23. Press ENTER when you are \
  24. done." 14 70 4 \
  25. "bsdgames" "The BSD text games collection" "on" \
  26. "sastroid" "An asteroids clone that uses SVGAlib" "on" \
  27. "koules" "An SVGAlib arcade game" "on" \
  28. "lizards" "Lizards video game" "on" \
  29. 2> $TMP/SeTpkgs
  30. if [ $? = 1 -o $? = 255 ]; then
  31.  rm -f $TMP/SeTpkgs
  32.  > $TMP/SeTnewtag
  33.  for pkg in bsdgames koules sastroid lizards ; do
  34.   echo "$pkg: SKP" >> $TMP/SeTnewtag
  35.  done
  36.  exit
  37. fi
  38. cat /dev/null > $TMP/SeTnewtag
  39. for PACKAGE in bsdgames sastroid koules lizards ; do
  40.  if fgrep \"$PACKAGE\" $TMP/SeTpkgs 1> /dev/null 2> /dev/null ; then
  41.   echo "$PACKAGE: ADD" >> $TMP/SeTnewtag
  42.  else
  43.   echo "$PACKAGE: SKP" >> $TMP/SeTnewtag
  44.  fi
  45. done
  46. rm -f $TMP/SeTpkgs
  47.