@ -235,6 +235,21 @@ Also auto refresh dired, but be quiet about it. [[http://whattheemacsd.com/sane-
#+end_src
* Pandoc
Convert between formats, like from org to html.
Pandoc needs to be installed on the system
#+BEGIN_SRC shell
sudo apt install pandoc
#+END_SRC
Pandoc-mode is a minor mode to interact with pandoc
#+BEGIN_SRC emacs-lisp
(use-package pandoc-mode
:ensure t
:init
(add-hook 'markdown-mode-hook 'pandoc-mode))
#+END_SRC
* Org Mode
** Installation
Although org mode ships with Emacs, the latest version can be installed externally. The configuration here follows the [[http://orgmode.org/elpa.html ][Org mode ELPA Installation instructions. ]]
@ -1427,34 +1442,34 @@ _v_ verify setup _f_ check _s_ select
* Custom key mappings
** Escape stuff
Standard is C-g to exit. But with the coming introduction of evil, ESC should be the default key for escaping stuff.
I just use general.el to define keys and keymaps.
#+BEGIN_SRC emacs-lisp
(defun minibuffer-keyboard-quit ()
"Abort recursive edit.
In Delete Selection mode, if the mark is active, just deactivate it;
then it takes a second \\[keyboard-quit] to abort the minibuffer."
(interactive)
(if (and delete-selection-mode transient-mark-mode mark-active)
(setq deactivate-mark t)
(when (get-buffer "*Completions* ") (delete-windows-on "*Completions* "))
(abort-recursive-edit)))
(with-eval-after-load 'evil-maps
(define-key evil-normal-state-map [escape] 'keyboard-quit)
(define-key evil-visual-state-map [escape] 'keyboard-quit))
;(with-eval-after-load 'swiper-map
; (define-key ivy-minibuffer-map [escape] 'keyboard-quit)
; (define-key swiper-map [escape] 'keyboard-quit)
;)
(define-key minibuffer-local-map [escape] 'minibuffer-keyboard-quit)
(define-key minibuffer-local-ns-map [escape] 'minibuffer-keyboard-quit)
(define-key minibuffer-local-completion-map [escape] 'minibuffer-keyboard-quit)
(define-key minibuffer-local-must-match-map [escape] 'minibuffer-keyboard-quit)
(define-key minibuffer-local-isearch-map [escape] 'minibuffer-keyboard-quit)
(global-set-key [escape] 'evil-exit-emacs-state)
#+END_SRC
#+BEGIN_SRC emacs-lisp
(use-package general
:ensure t
)
#+END_SRC
Now some keymaps.
If there is no map defined, it is considered the global key map.
#+BEGIN_SRC emacs-lisp
(general-define-key
:states '(normal visual insert emacs)
:prefix "SPC"
:non-normal-prefix "M-SPC"
"TAB" '(ivy-switch-buffer :which-key "prev buffer")
"SPC" '(counsel-M-x :which-key "M-x"))
#+END_SRC
A map for org-mode
#+BEGIN_SRC emacs-lisp
(general-define-key
:states '(normal visual insert emacs)
:keymaps 'org-mode-map
:prefix "SPC"
:non-normal-prefix "M-SPC"
"t" '(counsel-org-tag :which-key "org-tag"))
#+END_SRC
* Quality of Life
** Default Window Size
#+BEGIN_SRC emacs-lisp