Permalink
Browse files

ignore hidden files (eg .swp)

  • Loading branch information...
1 parent b0a9bf6 commit 0d3693deeccaca72a55e8b5c0d6443fa563946a3 @jblomo jblomo committed Nov 23, 2012
Showing with 10 additions and 6 deletions.
  1. +1 −0 .gitignore
  2. +9 −6 vrepl/src/vrepl/core.clj
View
@@ -1,6 +1,7 @@
.cake
pom.xml
*.jar
+*.sw[po]
*.war
.lein-deps-sum
.DS_Store
View
@@ -15,12 +15,15 @@
(defn reload! [vfs-filename]
- (let [path (.getPath vfs-filename)]
- (println "Reloading:" path)
- (case (.getExtension vfs-filename)
- "clj" (output-clj! (load-file path))
- "cljs" "CLJS not implemented yet"
- (println "I have no idea what to do with" path))))
+ (when-not (-> vfs-filename
+ .getBaseName
+ (.startsWith "."))
+ (let [path (.getPath vfs-filename)]
+ (println "Reloading:" path)
+ (case (.getExtension vfs-filename)
+ "clj" (output-clj! (load-file path))
+ "cljs" "CLJS not implemented yet"
+ (println "I have no idea what to do with" path)))))
(defn monitor-files! [path]
(let [fm (DefaultFileMonitor. (reify FileListener

0 comments on commit 0d3693d

Please sign in to comment.