Skip to content

Instantly share code, notes, and snippets.

View cddr's full-sized avatar

Andy Chambers cddr

View GitHub Profile
./long-running-proc
#Ctrl-Z # stops the job
bg # starts it running in the background
disown %1 # detaches this process from the current shell
@cddr
cddr / gist:2977107
Created June 23, 2012 06:16
edit file that asdf failed to load
(defmethod asdf:perform :around ((op asdf:compile-op) (component asdf:cl-source-file))
(restart-case (call-next-method)
(slime-edit ()
:report "Edit file which failed to compile."
(progn
(ed-in-emacs (asdf::component-pathname component))
(abort)))))
(defun rangecheck (rc)
(lambda (actual)
(let* ((comparator (intern (property rc "Comparator") #.*package*))
(unit (find-def (kid-like 'measurementunitref :in rc)))
(test (case comparator
(LT '<)
(LE '<=)
(GT '>)
(GE '>=)
(EQ '=)