 
 (defn- dir*
   [nsname]
-  (run! prn
-    (distinct (sort (concat
-                      (public-syms nsname)
-                      (public-syms (symbol (str (name nsname) "$macros"))))))))
+  (print
+    (with-out-str
+      (run! prn
+        (distinct (sort (concat
+                          (public-syms nsname)
+                          (public-syms (symbol (str (name nsname) "$macros"))))))))))
 
 (defn- apropos*
   [str-or-pattern]


(defn- print-doc
  [m]
  (repl/print-doc (update m :doc (if (user-interface-idiom-ipad?)
                                   identity
                                   reflow))))

(defn- doc*
  [sym]


(defn- find-doc*
  [re-string-or-pattern]
  (print
    (with-out-str
      (let [re       (re-pattern re-string-or-pattern)
            sym-docs (sort-by first
                       (mapcat (fn [ns]
                                 (map (juxt first (comp :doc second))
                                   (get-in @st [::ana/namespaces ns :defs])))
                         (all-ns)))]
        (doseq [[sym doc] sym-docs
                :when (and doc
                           (name sym)
                           (or (re-find re doc)
                               (re-find re (name sym))))]
          (doc* sym))))))

(defn- source*
  [sym]
