Constructing a tail cmd I wrote this without much thought:

(defn- tail-cmd
  "Construct a tail cmd"
  [file n &amp; ignore-patterns]
  (clojure.string/join
   " | "
   (flatten [(format "tail -n %s -f %s" (or n 200) file)
             (map #(format "grep --line-buffered -v \"%s\"" %)
                  ignore-patterns)])))


On further thought, I'm not sure if it can simplified further. Can it be?
You may or may not consider this simpler:

(defn tail-cmd-2
  "Construct a tail cmd"
  [file n &amp; ignore-patterns]
  (str "cat "
       file
       " | "
       (apply str (map #(format "grep -v \"%s\" | " %) ignore-patterns))
       "tail -f "
       (if n (str "-n " n))))


Or if you're willing to use the non-standard clojure.core.strint library, you can do the following.

(defn tail-cmd-5
  "Construct a tail cmd"
  [file n &amp; ignore-patterns]
  (let [greps   (apply str (for [p ignore-patterns] (format "grep -v \"%s\" | " p)))
        minus-n (if n (str "-n " n))]
    (&lt;&lt; "cat ~{file} | ~{greps} tail -f ~{minus-n}")))


Here's the library source:
https://github.com/clojure/core.incubator