Permalink
Browse files

Cleaned up all the ns forms.

SLAMHOUND! BOOM!!!
  • Loading branch information...
1 parent 85d9e5c commit 9bb0b5b3ca1050f15f8cce3e63f103dfb5ce1542 @iantruslove iantruslove committed Aug 17, 2015
Showing with 24 additions and 29 deletions.
  1. +12 −15 src/static/core.clj
  2. +9 −11 src/static/io.clj
  3. +3 −3 test/static/test/core.clj
View
@@ -1,26 +1,23 @@
(ns static.core
- (:gen-class)
- (:require [watchtower.core :as watcher]
- ;;[hiccup-bridge.core :as hic]
- [clojure.walk :as walk]
- [net.cgrand.enlive-html :as enlive]
+ (:require [clojure.java.browse :as browse]
[clojure.string :as str]
- [clojure.tools.logging :as log]
[clojure.tools.cli :as cli]
- [clojure.java.browse :as browse]
- [ring.adapter.jetty :as jetty]
- ;;[ring.middleware.file :refer :all]
- [ring.util.response :refer :all]
+ [clojure.tools.logging :as log]
+ [hiccup.core :as hiccup]
[hiccup.page :refer :all]
[hiccup.util :refer :all]
- [hiccup.core :as hiccup]
- [stringtemplate-clj.core :as string-template]
+ [net.cgrand.enlive-html :as enlive]
+ [ring.adapter.jetty :as jetty]
+ [ring.util.response :refer :all]
[static.config :as config]
- [static.io :as io])
+ [static.io :as io]
+ [stringtemplate-clj.core :as string-template]
+ [watchtower.core :as watcher])
(:import (java.io File)
(java.net URL)
- (org.apache.commons.io FileUtils FilenameUtils)
- (java.text SimpleDateFormat)))
+ (java.text SimpleDateFormat)
+ (org.apache.commons.io FileUtils FilenameUtils))
+ (:gen-class))
(defmacro define-template
"wrap a template in the necessary calls to return correctly"
View
@@ -1,14 +1,12 @@
(ns static.io
- (:require [clojure.tools.logging :as log]
- [clojure.java.shell :as sh]
- [cssgen :as cssgen]
- [hiccup.core :refer :all]
- [stringtemplate-clj.core :as string-template]
- [static.config :as config])
- (:import (org.pegdown PegDownProcessor)
- (java.io File)
- (java.io InputStreamReader OutputStreamWriter)
- (org.apache.commons.io FileUtils FilenameUtils)))
+ (:require [clojure.java.shell :as sh]
+ [clojure.tools.logging :as log]
+ [cssgen :as css-gen]
+ [static.config :as config]
+ [stringtemplate-clj.core :as string-template])
+ (:import (java.io File)
+ (org.apache.commons.io FileUtils FilenameUtils)
+ (org.pegdown PegDownProcessor)))
(defn- split-file [content]
(let [idx (.indexOf content "---" 4)]
@@ -114,7 +112,7 @@
(let [metadata {:extension "css" :template :none}
content (read-string
(slurp file :encoding (:encoding (config/config))))
- to-css #(clojure.string/join "\n" (doall (map cssgen/css %)))]
+ to-css #(clojure.string/join "\n" (doall (map css-gen/css %)))]
[metadata (delay (binding [*ns* (the-ns 'static.core)] (-> content eval to-css)))]))
(defn read-doc [f]
@@ -1,8 +1,8 @@
(ns static.test.core
- (:require [static.core :refer :all]
+ (:require [clojure.test :refer :all]
+ [static.core :refer :all]
[static.io :refer :all]
- [static.test.dummy-fs :refer :all]
- [clojure.test :refer :all])
+ [static.test.dummy-fs :refer :all])
(:import (java.io File)
(org.apache.commons.io FileUtils)))

0 comments on commit 9bb0b5b

Please sign in to comment.