Browse files

Support fish which uses "; and" rather than "&&" to join commands

  • Loading branch information...
stig committed Dec 29, 2016
1 parent 075e5f9 commit 2c8197e5d7813734d6a49f9b9c0b227b7ae022a8
Showing with 9 additions and 1 deletion.
  1. +9 −1 git-auto-commit-mode.el
@@ -51,6 +51,13 @@ If non-nil a git push will be executed after each commit."
:group 'git-auto-commit-mode
:type 'boolean)
(defcustom gac-shell-and " && "
"How to join commands together in the shell. For fish shell,
you want to customise this to: \" ; and \" instead of the default."
:tag "Join shell commands"
:group 'git-auto-commit-mode
:type 'string)
(defun gac-relative-file-name (filename)
"Find the path to FILENAME relative to the git directory."
(let* ((git-dir
@@ -111,7 +118,8 @@ Default to FILENAME."
(default-directory (file-name-directory buffer-file)))
(concat "git add " (shell-quote-argument filename)
" && git commit -m " (shell-quote-argument commit-msg)))))
"git commit -m " (shell-quote-argument commit-msg)))))
(defun gac-push ()
"Push commits to the current upstream.

0 comments on commit 2c8197e

Please sign in to comment.