Adding ligatures and dired tweaks

This commit is contained in:
Chris Cochrun 2021-02-18 06:41:30 -06:00
parent ae8fde41e1
commit b4c9e64328
3 changed files with 80 additions and 3 deletions

36
init.el
View file

@ -7,8 +7,6 @@
gcs-done))
(add-hook 'emacs-startup-hook #'chris/display-startup-time)
(setq gc-cons-threshold 50000000)
(setq inhibit-startup-message t)
(scroll-bar-mode -1)
@ -83,6 +81,33 @@
(which-key-mode)
:defer 1)
(let ((alist '((?! . "\\(?:!\\(?:==\\|[!=]\\)\\)")
(?# . "\\(?:#\\(?:###?\\|_(\\|[!#(:=?[_{]\\)\\)")
(?$ . "\\(?:\\$>\\)")
(?& . "\\(?:&&&?\\)")
(?* . "\\(?:\\*\\(?:\\*\\*\\|[/>]\\)\\)")
(?+ . "\\(?:\\+\\(?:\\+\\+\\|[+>]\\)\\)")
(?- . "\\(?:-\\(?:-[>-]\\|<<\\|>>\\|[<>|~-]\\)\\)")
(?. . "\\(?:\\.\\(?:\\.[.<]\\|[.=?-]\\)\\)")
(?/ . "\\(?:/\\(?:\\*\\*\\|//\\|==\\|[*/=>]\\)\\)")
(?: . "\\(?::\\(?:::\\|\\?>\\|[:<-?]\\)\\)")
(?\; . "\\(?:;;\\)")
(?< . "\\(?:<\\(?:!--\\|\\$>\\|\\*>\\|\\+>\\|-[<>|]\\|/>\\|<[<=-]\\|=\\(?:=>\\|[<=>|]\\)\\||\\(?:||::=\\|[>|]\\)\\|~[>~]\\|[$*+/:<=>|~-]\\)\\)")
(?= . "\\(?:=\\(?:!=\\|/=\\|:=\\|=[=>]\\|>>\\|[=>]\\)\\)")
(?> . "\\(?:>\\(?:=>\\|>[=>-]\\|[]:=-]\\)\\)")
(?? . "\\(?:\\?[.:=?]\\)")
(?\[ . "\\(?:\\[\\(?:||]\\|[<|]\\)\\)")
(?\ . "\\(?:\\\\/?\\)")
(?\] . "\\(?:]#\\)")
(?^ . "\\(?:\\^=\\)")
(?_ . "\\(?:_\\(?:|?_\\)\\)")
(?{ . "\\(?:{|\\)")
(?| . "\\(?:|\\(?:->\\|=>\\||\\(?:|>\\|[=>-]\\)\\|[]=>|}-]\\)\\)")
(?~ . "\\(?:~\\(?:~>\\|[=>@~-]\\)\\)"))))
(dolist (char-regexp alist)
(set-char-table-range composition-function-table (car char-regexp)
`([,(cdr char-regexp) 0 font-shape-gstring]))))
(use-package evil
:init
(setq evil-want-integration t
@ -213,6 +238,13 @@
(setq format-all-formatters '("Emacs Lisp" emacs-lisp))
:defer 1)
(chris/leader-keys
"od" '(dired-jump :which-key "open dired here"))
(general-def 'normal dired-mode-map
"h" 'dired-up-directory
"l" 'dired-find-file
"q" 'kill-this-buffer)
(defun chris/org-mode-setup ()
(org-indent-mode +1)
(toc-org-mode +1)