summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--tag-emacs/emacs.d/init.org4
1 files changed, 4 insertions, 0 deletions
diff --git a/tag-emacs/emacs.d/init.org b/tag-emacs/emacs.d/init.org
index 68f2c7e..cf71075 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")