[submodule "packed"]
path = lib/packed
url = git@github.com:emacscollective/packed.git
+[submodule "page-break-lines"]
+ path = lib/page-break-lines
+ url = git@github.com:purcell/page-break-lines.git
[submodule "pdf-tools"]
path = lib/pdf-tools
url = git@github.com:politza/pdf-tools.git
-;;; init.el --- Amin Bandali's Emacs config -*- lexical-binding: t ; eval: (view-mode 1)-*-
+;;; init.el --- Amin Bandali's Emacs config -*- lexical-binding: t -*-
;; Copyright (C) 2018 Amin Bandali <bandali@gnu.org>
;; amin-... public variables or non-interactive functions
;; amin--... private anything (non-interactive), not safe for direct use
;; amin/... an interactive function; safe for M-x or keybinding
-;; amin:... an evil operator, motion, or command
;; amin|... a hook function
;; amin*... an advising function
;; amin@... a hydra command
;;; Code:
+\f
+;; * Initial setup
+
(defvar amin--before-user-init-time (current-time)
"Value of `current-time' when Emacs begins loading `user-init-file'.")
(message "Loading Emacs...done (%.3fs)"
(declare (indent defun) (debug t))
`(progn ,@(mapcar (lambda (x) (list 'setq x value)) vars)))
+\f
+;; * Core
+
;; (fringe-mode '(3 . 1))
(fringe-mode nil)
("h" . outline-hide-subtree)
("s" . outline-show-subtree)))
+\f
+;; * Borg's `layer/essentials'
+
(use-package dash
:config (dash-enable-font-lock))
;; (setq undo-tree-mode-lighter ""
;; undo-tree-auto-save-history t))
+\f
+;; * Editing
+
(use-package company
:defer 1
:bind
:config
(global-company-mode t))
+\f
+;; * Syntax and spell checking
+
(use-package flycheck
:defer 3
:hook (prog-mode . flycheck-mode)
(advice-add #'ispell-parse-output :filter-args
#'endless/replace-quote))
+\f
+;; * Programming modes
+
(use-package alloy-mode
:defer t
:config (setq alloy-basic-offset 2))
:defer t
:mode "\\.nix\\'")
+\f
+;; * Emacs Enhancements
+
(use-package which-key
:defer 1
:config (which-key-mode))
(use-package multi-term
:defer 1
- :bind (("C-c C-j" . term-line-mode)
- ("C-c m m" . multi-term)
- ("C-c m p" . multi-term-dedicated-toggle))
+ :bind (("C-c C-j" . term-line-mode)
+ ("C-c a s m m" . multi-term)
+ ("C-c a s m p" . multi-term-dedicated-toggle))
:config
(setq multi-term-program "/bin/screen"
;; TODO: add separate bindings for connecting to existing
term-unbind-key-alist
'("C-z" "C-x" "C-c" "C-h" "C-y" "<ESC>")))
+(use-package page-break-lines
+ :config
+ (global-page-break-lines-mode))
+
+\f
+;; * Email
+
(defvar amin-maildir (expand-file-name "~/mail/"))
(after! recentf
(add-to-list 'recentf-exclude amin-maildir))
(gnus-harvest-install 'message-x)
(gnus-harvest-install)))
+\f
+;; * Blogging
+
(use-package ox-hugo
:after ox)
(use-package ox-hugo-auto-export
:load-path "lib/ox-hugo")
+\f
+;; * Post initialization
+
(message "Loading %s...done (%.3fs)" user-init-file
(float-time (time-subtract (current-time)
amin--before-user-init-time)))
** First line
#+begin_src emacs-lisp :comments none
-;;; init.el --- Amin Bandali's Emacs config -*- lexical-binding: t ; eval: (view-mode 1)-*-
+;;; init.el --- Amin Bandali's Emacs config -*- lexical-binding: t -*-
#+end_src
Enable =view-mode=, which both makes the file read-only (as a reminder
;; amin-... public variables or non-interactive functions
;; amin--... private anything (non-interactive), not safe for direct use
;; amin/... an interactive function; safe for M-x or keybinding
-;; amin:... an evil operator, motion, or command
;; amin|... a hook function
;; amin*... an advising function
;; amin@... a hydra command
#+begin_src emacs-lisp :comments none
;;; Code:
+
+\f
+;; * Initial setup
#+end_src
** Emacs initialization
:CUSTOM_ID: core
:END:
+#+begin_src emacs-lisp :comments none
+\f
+;; * Core
+#+end_src
+
** Defaults
*** Time and battery in mode-line
* Borg's =layer/essentials=
+#+begin_src emacs-lisp :comments none
+\f
+;; * Borg's `layer/essentials'
+#+end_src
+
TODO: break this giant source block down into individual org sections.
#+begin_src emacs-lisp
* Editing
+#+begin_src emacs-lisp :comments none
+\f
+;; * Editing
+#+end_src
+
** Company
#+begin_src emacs-lisp
#+end_src
* Syntax and spell checking
+
+#+begin_src emacs-lisp :comments none
+\f
+;; * Syntax and spell checking
+#+end_src
+
#+begin_src emacs-lisp
(use-package flycheck
:defer 3
#+end_src
* Programming modes
+#+begin_src emacs-lisp :comments none
+\f
+;; * Programming modes
+#+end_src
+
** [[http://alloytools.org][Alloy]] (with [[https://github.com/dwwmmn/alloy-mode][alloy-mode]])
#+begin_src emacs-lisp
* Emacs Enhancements
+#+begin_src emacs-lisp :comments none
+\f
+;; * Emacs Enhancements
+#+end_src
+
** [[https://github.com/justbur/emacs-which-key][which-key]]
#+begin_quote
#+begin_src emacs-lisp
(use-package multi-term
:defer 1
- :bind (("C-c C-j" . term-line-mode)
- ("C-c m m" . multi-term)
- ("C-c m p" . multi-term-dedicated-toggle))
+ :bind (("C-c C-j" . term-line-mode)
+ ("C-c a s m m" . multi-term)
+ ("C-c a s m p" . multi-term-dedicated-toggle))
:config
(setq multi-term-program "/bin/screen"
;; TODO: add separate bindings for connecting to existing
'("C-z" "C-x" "C-c" "C-h" "C-y" "<ESC>")))
#+end_src
+** page-break-lines
+
+#+begin_src emacs-lisp
+(use-package page-break-lines
+ :config
+ (global-page-break-lines-mode))
+#+end_src
+
* Email
+#+begin_src emacs-lisp :comments none
+\f
+;; * Email
+#+end_src
+
#+begin_src emacs-lisp
(defvar amin-maildir (expand-file-name "~/mail/"))
(after! recentf
#+end_src
* Blogging
+
+#+begin_src emacs-lisp :comments none
+\f
+;; * Blogging
+#+end_src
+
** [[https://ox-hugo.scripter.co][ox-hugo]]
#+begin_src emacs-lisp
:CUSTOM_ID: post-initialization
:END:
+#+begin_src emacs-lisp :comments none
+\f
+;; * Post initialization
+#+end_src
+
Display how long it took to load the init file.
#+begin_src emacs-lisp
--- /dev/null
+Subproject commit 87e801efb816b24e83ebf84c052001e178e180bc