From 948a02ee75a6f1ed5af35359f5cccf0745f5b621 Mon Sep 17 00:00:00 2001 From: Kyle Meyer Date: Sun, 17 Nov 2013 15:55:17 -0500 Subject: Load git-annex.el on start up Forgot to require git-annex when I switched source to elpa --- init/km-git.el | 28 ++++++++++++++++++++++++++++ init/km-magit.el | 27 --------------------------- 2 files changed, 28 insertions(+), 27 deletions(-) create mode 100644 init/km-git.el delete mode 100644 init/km-magit.el (limited to 'init') diff --git a/init/km-git.el b/init/km-git.el new file mode 100644 index 0000000..8c5b08f --- /dev/null +++ b/init/km-git.el @@ -0,0 +1,28 @@ +(require 'git-annex) +(require 'magit) + +(defun km/magit-auto-commit () + (interactive) + (save-window-excursion + (magit-with-refresh + (shell-command "git --no-pager commit --all --message=auto")))) + +(define-key magit-status-mode-map (kbd "C-c C-u") 'km/magit-auto-commit) + +;; http://whattheemacsd.com/setup-magit.el-01.html +(defadvice magit-status (around magit-fullscreen activate) + (window-configuration-to-register :magit-fullscreen) + ad-do-it + (delete-other-windows)) +(defadvice magit-mode-quit-window (around magit-restore-screen activate) + ad-do-it + (jump-to-register :magit-fullscreen)) + +;; http://whattheemacsd.com/setup-magit.el-05.html +(defun km/magit-just-amend () + (interactive) + (save-window-excursion + (magit-with-refresh + (shell-command "git --no-pager commit --amend --reuse-message=HEAD")))) + +(define-key magit-status-mode-map (kbd "C-c C-a") 'km/magit-just-amend) diff --git a/init/km-magit.el b/init/km-magit.el deleted file mode 100644 index aa1621b..0000000 --- a/init/km-magit.el +++ /dev/null @@ -1,27 +0,0 @@ -(require 'magit) - -(defun km/magit-auto-commit () - (interactive) - (save-window-excursion - (magit-with-refresh - (shell-command "git --no-pager commit --all --message=auto")))) - -(define-key magit-status-mode-map (kbd "C-c C-u") 'km/magit-auto-commit) - -;; http://whattheemacsd.com/setup-magit.el-01.html -(defadvice magit-status (around magit-fullscreen activate) - (window-configuration-to-register :magit-fullscreen) - ad-do-it - (delete-other-windows)) -(defadvice magit-mode-quit-window (around magit-restore-screen activate) - ad-do-it - (jump-to-register :magit-fullscreen)) - -;; http://whattheemacsd.com/setup-magit.el-05.html -(defun km/magit-just-amend () - (interactive) - (save-window-excursion - (magit-with-refresh - (shell-command "git --no-pager commit --amend --reuse-message=HEAD")))) - -(define-key magit-status-mode-map (kbd "C-c C-a") 'km/magit-just-amend) -- cgit v1.2.3