diff options
author | Thanos Apollo <[email protected]> | 2024-02-10 07:08:37 +0200 |
---|---|---|
committer | Thanos Apollo <[email protected]> | 2024-02-10 07:08:37 +0200 |
commit | ba186fb17aa30e7a589066f91cc2e6db51a2f80a (patch) | |
tree | 4eadde66fe31c4147d59fd925c1093a85494303e /gnosis.el | |
parent | f13e1ddfef4d0a492d7ba738ff7d08b9a18ea138 (diff) |
Add gnosis-auto-push-command
Diffstat (limited to 'gnosis.el')
-rw-r--r-- | gnosis.el | 15 |
1 files changed, 13 insertions, 2 deletions
@@ -65,10 +65,21 @@ between two strings to consider them as similar." :group 'gnosis) (defcustom gnosis-auto-push nil - "Automatically run `git push' at the end of every review session." + "Automatically run `gnosis-auto-push-command' at the end of every review session." :type 'boolean :group 'gnosis) +(defcustom gnosis-auto-push-command "push" + "Git shell command to run at the end of a review session. + +Command specified will be executed when `gnosis-auto-push' is enabled. + +It should be provided as a string without the `git' prefix, assuming +that git is available in the system's PATH. For example, setting it +to \"push\" will execute the command 'git push'." + :type 'string + :group 'gnosis) + (defvar gnosis-images-dir (expand-file-name "images" gnosis-dir) "Gnosis images directory.") @@ -1027,7 +1038,7 @@ NOTE-NUM: The number of notes reviewed in the session." (shell-command (concat git " commit -m " (shell-quote-argument (concat (format "Total notes for session: %d " note-num))))) (when gnosis-auto-push - (shell-command (concat git " push"))) + (shell-command (concat git " " gnosis-auto-push-command))) (message "Review session finished. %d notes reviewed." note-num))) (defun gnosis-review--session (notes) |