Skip to content
clojure library that shakes your shell
Find file
Pull request Compare This branch is 23 commits behind sunng87:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
doc
src/shake
test/shake
.gitignore
README.md
project.clj

README.md

shake

A Clojure library shakes your shell.

Usage

Leiningen

[shake "0.1.1"]

Just That Simple

(use 'shake.core)

;; any shell command ...
(uname -a) ;;returns a #<UNIXProcess java.lang.UNIXProcess@1833160>

;; if you just want to see the output:
(binding [*print-output* true]
  (uname -a))

I/O

shake extends Process with clojure's IOFactory. So you can (input-stream) or (output-stream) the process to get a streamed I/O.

;; print output of `uname -a`
(print (slurp (input-stream (uname -a))))

Too Slow to Load (Verbose Clojure Warnings) ?

By default, shake indexes all executables under your PATH. To override this behavior, set environment variable SHAKE_PATH before you initialize the namespace shake.core.

License

Copyright © 2012 Sun Ning sunng@about.me

Distributed under the Eclipse Public License, the same as Clojure.

Something went wrong with that request. Please try again.