Add .base .local .other to list of tmp files.
authorOleksandr Gavenko <gavenkoa@gmail.com>
Sat, 09 Jul 2011 01:53:05 +0300
changeset 667 32cbaa8f4368
parent 666 994de1974616
child 668 07411bd9d7d2
Add .base .local .other to list of tmp files.
.emacs-my
--- a/.emacs-my	Thu Jul 07 09:09:48 2011 +0300
+++ b/.emacs-my	Sat Jul 09 01:53:05 2011 +0300
@@ -618,7 +618,12 @@
   )
 
 (defun my-file-name-tmp-p (file)
-  (string-match "\\(?:^#.*#\\|~\\|\\.orig\\|\\.log\\|^.?\\.diff\\|\\.stackdump\\|\\.rej\\)\\'" (file-name-nondirectory file)))
+  (string-match
+   `,(concat
+    "\\(?:^#.*#\\|~\\|^.?\\.diff\\|"
+    "\\." (regexp-opt '("base" "local" "orig" "other" "log" "stackdump" "rej"))
+    "\\)\\'")
+   (file-name-nondirectory file)))
 
 (defun my-dired-flag-tmp-files ()
   "Flag all temporary files for deletion."