summaryrefslogtreecommitdiff
path: root/Tools
diff options
context:
space:
mode:
authorRene Ladan <rene@FreeBSD.org>2023-04-30 13:39:33 +0200
committerRene Ladan <rene@FreeBSD.org>2023-04-30 13:40:21 +0200
commit8270a4ffc5efe1b91791a8eb0602aec553e4ae12 (patch)
tree1aefd1228226e962cd35bdea9bf0fd980a61fbbd /Tools
parentTools/scripts/rmport: remove extraneous trailing '/' in single-port commit me... (diff)
Tools/scripts/rmport: also cleanup when being trapped on a signal
This should get rid of stale gitrmlist* and gitlog* files.
Diffstat (limited to 'Tools')
-rwxr-xr-xTools/scripts/rmport6
1 files changed, 2 insertions, 4 deletions
diff --git a/Tools/scripts/rmport b/Tools/scripts/rmport
index 56adf93ea816..febfac91e4c8 100755
--- a/Tools/scripts/rmport
+++ b/Tools/scripts/rmport
@@ -352,6 +352,8 @@ usage()
# main
+trap cleanup 1 2 3 15
+
if [ ! -r ${INDEX} ] ; then
echo "${INDEX} not readable, exiting" >&2
exit 66
@@ -471,7 +473,3 @@ while [ "${answer}" = "y" ] ; do
done
commit
-
-cleanup
-
-# EOF