Skip to content

Instantly share code, notes, and snippets.

@emad-elsaid
Created December 24, 2017 21:52
Show Gist options
  • Save emad-elsaid/2df4f1935f695d329ec90f2b95d45736 to your computer and use it in GitHub Desktop.
Save emad-elsaid/2df4f1935f695d329ec90f2b95d45736 to your computer and use it in GitHub Desktop.
(setq quick-command "pwd")
(defun set-quick-command ()
"Set quick command"
(interactive)
(setq quick-command (read-string "Enter a quick commmand:")))
(defun execute-quick-command ()
"Execute a command that was set in quick-command variable"
(interactive)
(message "Executing: %s" quick-command)
(compilation-start quick-command))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment