Skip to content

Instantly share code, notes, and snippets.

@bouzuya
Created August 24, 2012 23:08
Show Gist options
  • Select an option

  • Save bouzuya/3456936 to your computer and use it in GitHub Desktop.

Select an option

Save bouzuya/3456936 to your computer and use it in GitHub Desktop.
:template-dirで返るパスが*base-dir*からの相対パスなので、compileが通らない。
(defn get-template-files
"Get all template files. Find specified directory with `:dir` option."
[& {:keys [dir] :or {dir (str *base-dir* (:template-dir *config*))}}] ;; :template-dirで返るパスが*base-dir*からの相対パスなので、compileが通らない。
(let [exts (get-watch-file-extensions)]
(filter
(fn [file]
(some #(has-extension? % file) exts))
(find-files dir))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment