slackbuilds/a/aaa_cycojesus/config/etc/rc.d/rc.local_shutdown
2011-09-03 23:26:36 +02:00

11 lines
339 B
Bash
Executable file

#!/bin/sh
PKGS_REPO=/home/installs/PKGs
# Move all recently built packages into our packages repository
mkdir -p $PKGS_REPO
find /tmp -name \*.t\?z -maxdepth 1 -exec mv {} $PKGS_REPO \;
# Clean up said repository of obsolete (not installed) packages
cd $PKGS_REPO
for i in *.t?z; do [ ! -e /var/adm/packages/${i%.t?z} ] && rm $i; done