Skip to content

Instantly share code, notes, and snippets.

@eschulte
Created February 8, 2010 20:22
Show Gist options
  • Save eschulte/298535 to your computer and use it in GitHub Desktop.
Save eschulte/298535 to your computer and use it in GitHub Desktop.
(defun sinatra-web-server (&optional edit-cmd-args)
"Run script/server. Dump output to a compilation buffer
allowing jumping between errors and source code. With optional
prefix argument allows editing of the server command arguments."
(interactive "P")
(let* ((script (buffer-file-name))
(command (if edit-cmd-args
(read-string "Run Ruby: " (concat script " "))
script)))
(ruby-compilation-run command)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment