fix rm of nothing
authorIan Kelling <iank@fsf.org>
Tue, 1 Jun 2021 03:03:39 +0000 (23:03 -0400)
committerIan Kelling <iank@fsf.org>
Tue, 1 Jun 2021 03:03:39 +0000 (23:03 -0400)
cedit

diff --git a/cedit b/cedit
index dfee11d592c78d1e64b7442fa8a003161c621922..9b21969b4ce204a518fd125f961af14a5c5881fb 100755 (executable)
--- a/cedit
+++ b/cedit
@@ -130,8 +130,8 @@ section. cedit is short for config edit.
       echo "$diff"
     fi
   fi
-  if ! $backup; then
-    rm -r $"$temp"
+  if ! $backup && $exists; then
+    rm -r "$temp"
   fi
   return $ret
 }