Skip to content

Instantly share code, notes, and snippets.

@amalloy
Created April 24, 2014 04:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save amalloy/11241974 to your computer and use it in GitHub Desktop.
Save amalloy/11241974 to your computer and use it in GitHub Desktop.
(reduce (fn [mentioned-files file]
(if (some #{file} mentioned-files)
mentioned-files
(let [duplicates (duplicates-of-file file files (:precision options))]
(when (seq duplicates)
(printf "%s\n" file)
(doseq [d duplicates]
(printf "%s\n" d))
(printf "\n"))
(concat mentioned-files duplicates))))
(), files)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment