Skip to content

Instantly share code, notes, and snippets.

@qharlie
Created July 12, 2012 22:00
Show Gist options
  • Save qharlie/3101369 to your computer and use it in GitHub Desktop.
Save qharlie/3101369 to your computer and use it in GitHub Desktop.
(defn write-htaccess [ips]
(spit "/home/q/htaccess"
(join "\n" (concat
'("order allow, deny")
(map (partial format "deny from %s") ips)
'("allow from all")))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment