diff options
author | Case Duckworth | 2021-01-21 08:38:38 -0600 |
---|---|---|
committer | Case Duckworth | 2021-01-21 08:38:38 -0600 |
commit | 68f0ed1ee3331cb2b148a6e3b8952c5eb005eb70 (patch) | |
tree | 8a0f9773140de8705515e60223177bcf809798c2 | |
parent | UI, Persistence (diff) | |
download | emacs-68f0ed1ee3331cb2b148a6e3b8952c5eb005eb70.tar.gz emacs-68f0ed1ee3331cb2b148a6e3b8952c5eb005eb70.zip |
Remove comments
-rw-r--r-- | early-init.el | 66 | ||||
-rw-r--r-- | init.el | 48 |
2 files changed, 53 insertions, 61 deletions
diff --git a/early-init.el b/early-init.el index 2e78e43..103e0b4 100644 --- a/early-init.el +++ b/early-init.el | |||
@@ -2,40 +2,41 @@ | |||
2 | ;; This file is automatically tangled from config.org. | 2 | ;; This file is automatically tangled from config.org. |
3 | ;; Hand edits will be overwritten! | 3 | ;; Hand edits will be overwritten! |
4 | 4 | ||
5 | ;; Disable loading of =package.el= | ||
6 | |||
7 | ;; I use =straight.el= instead. | ||
8 | |||
9 | |||
10 | ;; [[file:~/.emacs.d/config.org::*Disable loading of =package.el=][Disable loading of =package.el=:1]] | ||
11 | (setq package-enable-at-startup nil) | 5 | (setq package-enable-at-startup nil) |
12 | ;; Disable loading of =package.el=:1 ends here | 6 | (defun acdw/bootstrap-straight () |
13 | 7 | "Bootstrap straight.el." | |
14 | ;; Don't resize the frame when loading fonts | 8 | (defvar bootstrap-version) |
15 | 9 | (let ((bootstrap-file | |
16 | 10 | (expand-file-name | |
17 | ;; [[file:~/.emacs.d/config.org::*Don't resize the frame when loading fonts][Don't resize the frame when loading fonts:1]] | 11 | "straight/repos/straight.el/bootstrap.el" |
18 | (setq frame-inhibit-implied-resize t) | 12 | user-emacs-directory)) |
19 | ;; Don't resize the frame when loading fonts:1 ends here | 13 | (bootstrap-version 5)) |
20 | 14 | (unless (file-exists-p bootstrap-file) | |
21 | ;; Resize frame by pixels | 15 | (with-current-buffer |
22 | 16 | (url-retrieve-synchronously | |
23 | 17 | (concat | |
24 | ;; [[file:~/.emacs.d/config.org::*Resize frame by pixels][Resize frame by pixels:1]] | 18 | "https://raw.githubusercontent.com/" |
25 | (setq frame-resize-pixelwise t) | 19 | "raxod502/straight.el/develop/install.el") |
26 | ;; Resize frame by pixels:1 ends here | 20 | 'silent 'inhibit-cookies) |
27 | 21 | (goto-char (point-max)) | |
28 | ;; Shoe-horned from elsewhere in =config.org= | 22 | (eval-print-last-sexp))) |
29 | 23 | (load bootstrap-file nil 'nomessage))) | |
30 | ;; A fundamental tension of literal programming is logical versus | 24 | (unless (ignore-errors (acdw/bootstrap-straight)) |
31 | ;; programmatic ordering. I understand that's a problem it's meant to | 25 | (let ((msg "Straight.el didn't bootstrap correctly. Cloning directly")) |
32 | ;; solve but hey, maybe I'm not quite there yet. I feel that having this | 26 | (message "%s..." msg) |
33 | ;; weird shoe-horning of other bits of my config here, in a backwater | 27 | (call-process "git" nil |
34 | ;; heading in an appendix, isn't quite the future I wanted. But it's | 28 | (get-buffer-create "*bootstrap-straight-messages*") nil |
35 | ;; what I have for now. | 29 | "clone" |
36 | 30 | "https://github.com/raxod502/straight.el" | |
31 | (expand-file-name "straight/repos/straight.el" | ||
32 | user-emacs-directory)) | ||
33 | (message "%s...Done." msg) | ||
34 | (acdw/bootstrap-straight))) | ||
35 | |||
36 | (setq-default frame-inhibit-implied-resize t) | ||
37 | |||
38 | (setq-default frame-resize-pixelwise t) | ||
37 | 39 | ||
38 | ;; [[file:~/.emacs.d/config.org::*Shoe-horned from elsewhere in =config.org=][Shoe-horned from elsewhere in =config.org=:1]] | ||
39 | (add-to-list 'default-frame-alist | 40 | (add-to-list 'default-frame-alist |
40 | '(tool-bar-lines . 0)) | 41 | '(tool-bar-lines . 0)) |
41 | 42 | ||
@@ -50,4 +51,3 @@ | |||
50 | 51 | ||
51 | (scroll-bar-mode -1) | 52 | (scroll-bar-mode -1) |
52 | (horizontal-scroll-bar-mode -1) | 53 | (horizontal-scroll-bar-mode -1) |
53 | ;; Shoe-horned from elsewhere in =config.org=:1 ends here | ||
diff --git a/init.el b/init.el index d0e30b2..e8a67fd 100644 --- a/init.el +++ b/init.el | |||
@@ -2,36 +2,28 @@ | |||
2 | ;; This file is automatically tangled from config.org. | 2 | ;; This file is automatically tangled from config.org. |
3 | ;; Hand edits will be overwritten! | 3 | ;; Hand edits will be overwritten! |
4 | 4 | ||
5 | ;; Prefer newer files to older files | 5 | (setq-default load-prefer-newer t) |
6 | 6 | ||
7 | |||
8 | ;; [[file:~/.emacs.d/config.org::*Prefer newer files to older files][Prefer newer files to older files:1]] | ||
9 | (setq load-prefer-newer t) | ||
10 | ;; Prefer newer files to older files:1 ends here | ||
11 | |||
12 | ;; Load the config | ||
13 | |||
14 | ;; I keep most of my config in =config.el=, which is tangled directly | ||
15 | ;; from this file. This init just loads that file, either from lisp or | ||
16 | ;; directly from Org if it's newer. | ||
17 | |||
18 | |||
19 | ;; [[file:~/.emacs.d/config.org::*Load the config][Load the config:1]] | ||
20 | (let* (;; Speed up init | 7 | (let* (;; Speed up init |
21 | (gc-cons-threshold most-positive-fixnum) | 8 | (gc-cons-threshold most-positive-fixnum) |
22 | (file-name-handler-alist nil) | 9 | (file-name-handler-alist nil) |
23 | ;; Config file names | 10 | ;; Config file names |
24 | (conf (expand-file-name "config" | 11 | (config (expand-file-name "config" |
25 | user-emacs-directory)) | 12 | user-emacs-directory)) |
26 | (conf-el (concat conf ".el")) | 13 | (config.el (concat config ".el")) |
27 | (conf-org (concat conf ".org"))) | 14 | (config.org (concat config ".org")) |
28 | (unless (and (file-newer-than-file-p conf-el conf-org) | 15 | (straight-org-dir (expand-file-name "straight/build/org" |
29 | (load conf 'no-error)) | 16 | user-emacs-directory))) |
30 | ;; A plain require here just loads the older `org' | 17 | ;; Unless config.org is /newer/ than config.el, *or* the config |
31 | ;; in Emacs' install dir. We need to add the newer | 18 | ;; is able to be loaded without errors, load the config from |
32 | ;; one to the `load-path', hopefully that's all. | 19 | ;; config.org. |
33 | (add-to-list 'load-path (expand-file-name "straight/build/org" | 20 | (unless (or (file-newer-than-file-p config.org config.el) |
34 | user-emacs-directory)) | 21 | (load config 'no-error)) |
35 | (require 'org) | 22 | ;; A plain require here just loads the older `org' |
36 | (org-babel-load-file conf-org))) | 23 | ;; in Emacs' install dir. We need to add the newer |
37 | ;; Load the config:1 ends here | 24 | ;; one to the `load-path', hopefully that's all. |
25 | (when (file-exists-p straight-org-dir) | ||
26 | (add-to-list 'load-path straight-org-dir)) | ||
27 | ;; Load config.org | ||
28 | (require 'org) | ||
29 | (org-babel-load-file config.org))) | ||