diff options
-rw-r--r-- | config.org | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/config.org b/config.org index 61e5342..1bbd02e 100644 --- a/config.org +++ b/config.org | |||
@@ -312,6 +312,51 @@ from [[https://stackoverflow.com/questions/23659909/reverse-evaluation-order-of- | |||
312 | (winner-mode +1)) | 312 | (winner-mode +1)) |
313 | #+end_src | 313 | #+end_src |
314 | 314 | ||
315 | *** Windmove | ||
316 | |||
317 | #+begin_src emacs-lisp | ||
318 | (cuss windmove-create-window t | ||
319 | "Create windows in a direction if they don't exist.") | ||
320 | (cuss windomove-wrap-around t | ||
321 | "Wrap window movements around frame edges.") | ||
322 | |||
323 | (windmove-default-keybindings) | ||
324 | #+end_src | ||
325 | |||
326 | *** Pop some buffers up in the same window | ||
327 | |||
328 | from [[https://github.com/link0ff/emacs-init][link0ff]]. | ||
329 | |||
330 | #+begin_src emacs-lisp | ||
331 | (push `(,(rx bos | ||
332 | "*" | ||
333 | (or "Help" "Apropos" "Colors" "Buffer List" "Command History" | ||
334 | "Dictionary" "Locate" "Messages" "Proced" "eww" "snd" | ||
335 | (and "gud-" (+ (any "a-z0-9"))) | ||
336 | "compilation" "grep" "erlang" "haskell" | ||
337 | ;; Handle both "*shell*" and e.g. "*emacs-shell*" | ||
338 | ;; generated by `project-shell': | ||
339 | (and (? (* nonl) "-") "shell") | ||
340 | "Shell Command Output" | ||
341 | (and "SQL: " (+ (any "A-za-z"))) | ||
342 | "Diff" "vc-dir" "vc-log" "vc-search-log") | ||
343 | "*" | ||
344 | ;; Uniquifed buffer name with optional suffix in angle brackets | ||
345 | (? (and "<" (+ (not (any ">"))) ">")) | ||
346 | eos) | ||
347 | display-buffer-same-window | ||
348 | (inhibit-same-window . nil)) | ||
349 | display-buffer-alist) | ||
350 | |||
351 | (defun display-buffer-from-help-p (_buffer-name _action) | ||
352 | (unless current-prefix-arg | ||
353 | (with-current-buffer (window-buffer) | ||
354 | (eq major-mode 'help-mode)))) | ||
355 | |||
356 | (push '(display-buffer-from-help-p display-buffer-same-window) | ||
357 | display-buffer-alist) | ||
358 | #+end_src | ||
359 | |||
315 | ** Startup | 360 | ** Startup |
316 | 361 | ||
317 | #+begin_src emacs-lisp | 362 | #+begin_src emacs-lisp |