> I know though that I don't like the > "all" lock - I'd prefer to lock things for as little time as possible. > > OK. Then change the last line thus:
diff --git a/db-update b/db-update
index 426a236..2b55a9f 100755
--- a/db-update
+++ b/db-update
@@ -234,5 +234,5 @@ done
if [ -n "$to_add_any" ]; then
/bin/rm $to_add_any
fi
-cleanup
+rm -rf "$WORKDIR"
# vim: set ts=4 sw=4 noet ft=sh:
(Untested)

