diff options
author | Alan Pearce | 2017-02-22 10:28:08 +0100 |
---|---|---|
committer | Alan Pearce | 2017-02-22 10:28:08 +0100 |
commit | 24ec8ea3b03d84b22b25ebd895abc0e9ef07dfa5 (patch) | |
tree | 7773cb9cd41fbcc513ff85188f3494d6c20a7175 /tag-emacs | |
parent | 57e1d5e57102ced8bc48ac1621112ff7018dae2b (diff) | |
download | nixfiles-24ec8ea3b03d84b22b25ebd895abc0e9ef07dfa5.tar.lz nixfiles-24ec8ea3b03d84b22b25ebd895abc0e9ef07dfa5.tar.zst nixfiles-24ec8ea3b03d84b22b25ebd895abc0e9ef07dfa5.zip |
Emacs: Add process-exit-code command
Diffstat (limited to 'tag-emacs')
-rw-r--r-- | tag-emacs/emacs.d/init.org | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tag-emacs/emacs.d/init.org b/tag-emacs/emacs.d/init.org index 68f2c7ea..cf71075e 100644 --- a/tag-emacs/emacs.d/init.org +++ b/tag-emacs/emacs.d/init.org @@ -1234,6 +1234,10 @@ rather useful. (command (read-shell-command "Shell command: " nil nil nil))) (shell-command (replace-regexp-in-string "%" file-buffer command) to-current-buffer))) +(defun process-exit-code (program &rest args) + "Run PROGRAM with ARGS and return the exit code" + (apply 'call-process program nil nil nil args)) + (defun narrow-to-region-indirect (start end) "Restrict editing in this buffer to the current region, indirectly." (interactive "r") |