From 511f342511790d94959b3a21294edbae2970ef9b Mon Sep 17 00:00:00 2001 From: Ravi R Kiran Date: Mon, 29 May 2017 18:51:39 -0700 Subject: Extra top-level arguments for rsync Perhaps we simply need to find a way to only mirror those files that are managed by git. This would mess up new files, but that may be a price we are willing to pay. diff --git a/lisp/ravi-init-vc.el b/lisp/ravi-init-vc.el index da864ca..6c1d3a0 100644 --- a/lisp/ravi-init-vc.el +++ b/lisp/ravi-init-vc.el @@ -41,12 +41,16 @@ (setq magit-restore-window-configuration t) (add-hook 'magit-post-refresh-hook 'diff-hl-magit-post-refresh) + (defvar ravi/sync-top-level-host-extra-args "" + "Extra arguments to rsync for `ravi/sync-top-level'") + (defun ravi/sync-top-level () (when (and (boundp 'ravi/sync-top-level-host) (not (s-equals? (car (s-split-up-to "\\." (system-name) 1)) (car (s-split-up-to "\\." ravi/sync-top-level-host 1))))) (message "Synchronizing with %s" ravi/sync-top-level-host) - (shell-command (concat "rsync -a " (magit-toplevel) " " ravi/sync-top-level-host ":" (magit-toplevel))))) + (shell-command (concat "rsync -a " ravi/sync-top-level-host-extra-args + " " (magit-toplevel) " " ravi/sync-top-level-host ":" (magit-toplevel))))) (add-hook 'magit-post-refresh-hook 'ravi/sync-top-level) (use-package magit-svn -- cgit v0.10.1