Skip to content

Instantly share code, notes, and snippets.

@amirrajan
Created March 20, 2018 14:00
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 amirrajan/df21424ee3b3e3de6e4a0b5bba602278 to your computer and use it in GitHub Desktop.
Save amirrajan/df21424ee3b3e3de6e4a0b5bba602278 to your computer and use it in GitHub Desktop.
(defun execute-random-shiz (beg end)
"Select an are, run this command, and execute whatever you want"
(interactive "r")
(save-excursion
(eshell-command (concat "rake" "sql --script=" "\"" (buffer-substring-no-properties beg end) "\""))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment