Skip to content

Instantly share code, notes, and snippets.

@ober
Created September 29, 2015 05:31
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 ober/9ef5804b239f0c3c94b9 to your computer and use it in GitHub Desktop.
Save ober/9ef5804b239f0c3c94b9 to your computer and use it in GitHub Desktop.
loop/recur
(defn list-files
"Get list of all files in there"
(loop [ files #{} ]
(let [ hit (s3/list-objects cred "cloudtrail-cs") ]
(if (:truncated? hit)
(recur (conj files (:objects hit)))
files))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment