mirror of
https://github.com/correl/dotfiles.git
synced 2024-12-18 03:00:11 +00:00
[emacs] full-screen magit status
Advises the magit buffer to open full-screened, and restore the original window configuration when magit is quit. Based on the post http://whattheemacsd.com/setup-magit.el-01.html and ideas from the comments there.
This commit is contained in:
parent
90b572a6b8
commit
447a3818e9
1 changed files with 13 additions and 0 deletions
|
@ -19,6 +19,19 @@
|
|||
(require 'auto-complete-config)
|
||||
(ac-config-default)
|
||||
|
||||
;; Magit
|
||||
(defun magit-fullscreen ()
|
||||
(defadvice magit-status (around magit-fullscreen activate)
|
||||
(window-configuration-to-register :magit-fullscreen)
|
||||
ad-do-it
|
||||
(delete-other-windows))
|
||||
|
||||
(defadvice magit-quit-window (around magit-restore-screen activate)
|
||||
ad-do-it
|
||||
(jump-to-register :magit-fullscreen)))
|
||||
|
||||
(eval-after-load 'magit '(magit-fullscreen))
|
||||
|
||||
;; Smex
|
||||
(global-set-key (kbd "M-x") 'smex)
|
||||
(global-set-key (kbd "M-X") 'smex-major-mode-commands)
|
||||
|
|
Loading…
Reference in a new issue