#+begin_src emacs-lisp
(bind-keys
- ("C-c b B" . ibuffer-list-buffers)
("C-c b k" . kill-this-buffer)
+ ("C-c s s" . save-buffer)
("C-c b s" . save-buffer)
("C-c S" . save-buffer)
("C-c o" . other-window)
:config
(setq org-src-tab-acts-natively t
org-src-preserve-indentation nil
- org-edit-src-content-indentation 0)
+ org-edit-src-content-indentation 0
+ org-log-done 'time)
:hook (org-mode . org-indent-mode))
(use-package org-notmuch
:hook (eshell-mode . amin|eshell-setup))
#+end_src
+*** Ibuffer
+
+#+begin_src emacs-lisp
+(use-package ibuffer
+ :bind
+ (("C-x C-b" . ibuffer-other-window)
+ ("C-c b B" . ibuffer-other-window)
+ :map ibuffer-mode-map
+ ("P" . ibuffer-backward-filter-group)
+ ("N" . ibuffer-forward-filter-group)
+ ("M-p" . ibuffer-do-print)
+ ("M-n" . ibuffer-do-shell-command-pipe-replace))
+ :config
+ ;; Use human readable Size column instead of original one
+ (define-ibuffer-column size-h
+ (:name "Size" :inline t)
+ (cond
+ ((> (buffer-size) 1000000) (format "%7.1fM" (/ (buffer-size) 1000000.0)))
+ ((> (buffer-size) 100000) (format "%7.0fk" (/ (buffer-size) 1000.0)))
+ ((> (buffer-size) 1000) (format "%7.1fk" (/ (buffer-size) 1000.0)))
+ (t (format "%8d" (buffer-size)))))
+ :custom
+ (ibuffer-saved-filter-groups
+ '(("default"
+ ("dired" (mode . dired-mode))
+ ("org" (name . "^.*org$"))
+ ("web"
+ (or
+ (mode . web-mode)
+ (mode . css-mode)
+ (mode . scss-mode)
+ (mode . js2-mode)))
+ ("shell"
+ (or
+ (mode . eshell-mode)
+ (mode . shell-mode)))
+ ("notmuch" (name . "\*notmuch\*"))
+ ("programming"
+ (or
+ (mode . python-mode)
+ (mode . c++-mode)
+ (mode . emacs-lisp-mode)))
+ ("emacs"
+ (or
+ (name . "^\\*scratch\\*$")
+ (name . "^\\*Messages\\*$"))))))
+ (ibuffer-formats
+ '((mark modified read-only locked " "
+ (name 18 18 :left :elide)
+ " "
+ (size-h 9 -1 :right)
+ " "
+ (mode 16 16 :left :elide)
+ " " filename-and-process)
+ (mark " "
+ (name 16 -1)
+ " " filename)))
+ :hook (ibuffer . (lambda () (ibuffer-switch-to-saved-filter-groups "default"))))
+#+end_src
+
* Borg's =layer/essentials=
TODO: break this giant source block down into individual org sections.
(company-minimum-prefix-length 1)
(company-selection-wrap-around t)
(company-dabbrev-char-regexp "\\sw\\|\\s_\\|[-_]")
+ (company-dabbrev-downcase nil)
+ (company-dabbrev-ignore-case nil)
:config
(global-company-mode t))
#+end_src
(use-package emmet-mode
:bind* (("C-)" . emmet-next-edit-point)
("C-(" . emmet-prev-edit-point))
- :init
+ :config
+ (unbind-key "C-j" emmet-mode-keymap)
(setq emmet-move-cursor-between-quotes t)
:hook (web-mode css-mode html-mode sgml-mode))
#+end_src