Skip to content

Instantly share code, notes, and snippets.

@KingC100
Last active June 17, 2017 17:51
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KingC100/1b256cf3eab0aa37f714 to your computer and use it in GitHub Desktop.
Save KingC100/1b256cf3eab0aa37f714 to your computer and use it in GitHub Desktop.
dot->png use to sbcl.
(defun dot->png (fname thunk)
(with-open-file (*standard-output*
fname
:direction :output
:if-exists :supersede)
(funcall thunk))
(shell (concatenate 'string "dot -Tpng -O " fname)))
(defun shell (x)
(run-program "/bin/sh" (list "-c" x) :output t))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment