Skip to content

Instantly share code, notes, and snippets.

@c02y
Last active April 15, 2019 10:06
Show Gist options
  • Save c02y/bee5e8acf494726298e26fe96079e39b to your computer and use it in GitHub Desktop.
Save c02y/bee5e8acf494726298e26fe96079e39b to your computer and use it in GitHub Desktop.
STDOUT in terminal according to DISPLAY
;; omit the result to STDOUT after return when using emacs/emacsclient -e "expression"
(when (not (display-graphic-p))
(define-advice server-eval-and-print (:filter-args (args) no-print)
(list (car args) nil)))
(bind-keys :map prog-mode-map
("C-c a a" . align)
("C-c a r" . align-regexp))
# Put this into org-mode-map
("C-c l" . org-store-link)
# comment out this line, or enabing flyspell fails
;; (setq ispell-personal-dictionary "~/.emacs.d/ispell_en_US")
(bind-key* "C-c a" 'org-agenda)
(setq org-agenda-span 31
org-agenda-start-on-weekday nil
org-agenda-start-day "-7d")
(setq org-agenda-files (list "~/Org/todo.org"
;; "~/Org/school.org"
;; "~/Org/home.org"
))
# remove "org agenda seems very slow..." part
(bind-keys :map prog-mode-map
("C-c A a" . align)
("C-c A r" . align-regexp))
(dolist (m (list c-mode-map c++-mode-map))
(bind-keys :map m
:prefix-map align-prefix-map
:prefix "C-c A"
;; ("a" . align)
;; ("r" . align-regexp)
("c" . align-c-comments)
("m" . align-c-macros)))
remove toggle-trainling-whitespace-display and C-c e in init.el
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment