diff options
author | Aaron Griffin <aaronmgriffin@gmail.com> | 2008-05-07 07:40:02 +0200 |
---|---|---|
committer | Aaron Griffin <aaronmgriffin@gmail.com> | 2008-05-07 07:40:02 +0200 |
commit | cbd6533816b1c27aab268b5c8f823345be8e12ed (patch) | |
tree | 49821e3cda85d05789f51fa1a0bc13833545ce60 | |
parent | 0cb6e7ab0840196c8b9c0dda64e50fa535b17707 (diff) | |
download | dbscripts-cbd6533816b1c27aab268b5c8f823345be8e12ed.tar.gz dbscripts-cbd6533816b1c27aab268b5c8f823345be8e12ed.tar.xz |
Properly clean up stating dirs after a success
Remove all package file we added or removed
Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
-rwxr-xr-x | db-update | 6 |
1 files changed, 5 insertions, 1 deletions
@@ -186,7 +186,6 @@ if [ -n "$REMPKGS" ]; then for rem in $to_rem; do if [ -f "$ftppath/$rem" ]; then /bin/rm "$ftppath/$rem" - /bin/rm "$rem" fi done else @@ -200,9 +199,14 @@ fi if [ $(/bin/ls "$WORKDIR/build/" 2>/dev/null | wc -l) != 0 ]; then echo "Copying new files to '$ftppath'" /bin/cp -r "$WORKDIR/build/"* "$ftppath" + echo "Cleaning staging dir" + echo "/bin/rm $to_add $to_rem" + /bin/rm $to_add $to_rem else echo "Nothing to copy, no work done" fi + + cleanup # vim: set ts=4 sw=4 noet ft=sh: |