summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Tom Willemse2013-12-30 23:14:18 +0100
committerGravatar Tom Willemse2013-12-30 23:14:18 +0100
commitf642808f60c76335ca3d325d516cb62540b9970f (patch)
tree22620febb56229f760844e10bd0c45fb2bcd8301
parentee4285ac1fb202aac9aaaa4821e23b020d35d7ee (diff)
downloademacs-f642808f60c76335ca3d325d516cb62540b9970f.tar.gz
emacs-f642808f60c76335ca3d325d516cb62540b9970f.zip
Reorder advice
-rw-r--r--.emacs.d/init.el38
1 files changed, 20 insertions, 18 deletions
diff --git a/.emacs.d/init.el b/.emacs.d/init.el
index 6c217e1..7840248 100644
--- a/.emacs.d/init.el
+++ b/.emacs.d/init.el
@@ -818,7 +818,26 @@ If no direction is given, don't split."
"Get the hook name for MODE."
(intern (concat (symbol-name mode) "-mode-hook"))))
-;;;; aliases
+;;;;; Advice
+
+(defadvice org-agenda-redo (after ext:org-agenda-redo-add-appts)
+ "Pressing `r' on the agenda will also add appointments."
+ (progn
+ (setq appt-time-msg-list nil)
+ (org-agenda-to-appt)))
+
+(defadvice term-handle-exit (after oni:kill-buffer-after-exit activate)
+ "Kill the term buffer if the process finished."
+ (kill-buffer (current-buffer)))
+
+(defadvice windmove-do-window-select
+ (around init-windmove-stumpwm activate)
+ "If no window can be moved to, move stumpwm."
+ (condition-case err
+ ad-do-it
+ (error (stumpwm-command (format "move-focus %s" (ad-get-arg 0))))))
+
+;;;; Aliases
(defalias 'yes-or-no-p 'y-or-n-p)
(defalias 'dabbrev-expand 'hippie-expand)
@@ -1258,13 +1277,6 @@ If no direction is given, don't split."
"~/.emacs.d/vendor-lisp/mozrepl"
"~/.emacs.d/vendor-lisp/eap" "/usr/share/emacs/site-lisp")))
-(defadvice windmove-do-window-select
- (around init-windmove-stumpwm activate)
- "If no window can be moved to, move stumpwm."
- (condition-case err
- ad-do-it
- (error (stumpwm-command (format "move-focus %s" (ad-get-arg 0))))))
-
(global-set-key (kbd "C-c S") #'split-window-right)
(global-set-key (kbd "C-c s") #'split-window-below)
(global-set-key (kbd "C-c Q") #'delete-other-windows)
@@ -1277,16 +1289,6 @@ If no direction is given, don't split."
(global-set-key (kbd "C-c -") #'decrease-number-at-point)
(global-set-key (kbd "C-c +") #'increase-number-at-point)
-(defadvice org-agenda-redo (after ext:org-agenda-redo-add-appts)
- "Pressing `r' on the agenda will also add appointments."
- (progn
- (setq appt-time-msg-list nil)
- (org-agenda-to-appt)))
-
-(defadvice term-handle-exit (after oni:kill-buffer-after-exit activate)
- "Kill the term buffer if the process finished."
- (kill-buffer (current-buffer)))
-
(add-to-list 'debug-ignored-errors "^Can't shift all lines enough")
(enable '(downcase-region narrow-to-page narrow-to-region scroll-left