1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
|
#!/bin/sh -e
# Base Directory of jed-extra S-Lang scripts
LIBDIR=/usr/share/jed/jed-extra
# S-Lang script for setup, preparsing, and documentation generation
PREPARSE=/usr/share/jed/compile/jed-extra-preparse.sl
# Generated files (remove in both cases, because dirs or *.sl files
# may have been (re)moved or renamed)
FILES='( -name *.slc -o -name *.dfa -o -name ini.sl* -o -name libfuns.txt* )'
case "$1" in
install)
find $LIBDIR $FILES -print0 | xargs -0 --no-run-if-empty rm
jed-script $PREPARSE || true
# don't worry if jed-script is missing, because jed runs this
# script again at installation
;;
remove)
find $LIBDIR $FILES -print0 | xargs -0 --no-run-if-empty rm
;;
*)
echo "unknown argument --> \"$1"\" >&2
exit 1
;;
esac
|