General & minor refactor+cleanup

This commit is contained in:
Henrik Lissner 2017-11-05 17:16:13 +01:00
parent 0c2b1b5a93
commit c45e2c4918
No known key found for this signature in database
GPG key ID: 5F6C0EA160557395
8 changed files with 33 additions and 35 deletions

View file

@ -7,7 +7,7 @@ MODULES=$(patsubst modules/%, %, $(shell find modules/ -maxdepth 2 -type d))
all: autoloads autoremove install all: autoloads autoremove install
## Aliases ## Shortcuts
a: autoloads a: autoloads
i: install i: install
u: update u: update
@ -77,7 +77,7 @@ run:
# Diagnoses potential OS/environment issues # Diagnoses potential OS/environment issues
doctor: doctor:
@./bin/doom-doctor @bin/doom-doctor
## Internal tasks ## Internal tasks
init.el: init.el:

View file

@ -1,5 +1,5 @@
#!/bin/sh #!emacs --script
":"; exec emacs --no-site-file --script "$0" -- "$@" # -*-emacs-lisp-*- ;;; bin/org-tangle -*- lexical-binding: t; -*-
;; Extracts source blocks from org files and prints them to stdout. Debug/info ;; Extracts source blocks from org files and prints them to stdout. Debug/info
;; messages are directed to stderr and can be ignored. -l/--lang can be used to ;; messages are directed to stderr and can be ignored. -l/--lang can be used to
@ -10,7 +10,7 @@
;; org-tangle modules/ui/doom/README.org > install_fira_mono.sh ;; org-tangle modules/ui/doom/README.org > install_fira_mono.sh
;; org-tangle -l sh modules/lang/go/README.org | sh ;; org-tangle -l sh modules/lang/go/README.org | sh
(load "~/.emacs.d/core/core.el" nil t) (load (expand-file-name "../core/core.el" (file-name-directory load-file-name)) nil t)
(require 'org-install) (require 'org-install)
(require 'org) (require 'org)

View file

@ -16,9 +16,8 @@ If neither is available, run all tests in all enabled modules."
(load (expand-file-name "core/core.el" user-emacs-directory) nil t) (load (expand-file-name "core/core.el" user-emacs-directory) nil t)
(doom-initialize-modules nil)) (doom-initialize-modules nil))
;; collect targets ;; collect targets
(cond ((and command-line-args-left (cond ((and argv (equal (car argv) "--"))
(equal (car command-line-args-left) "--")) (cl-loop for arg in argv
(cl-loop for arg in (cdr argv)
if (equal arg "core") if (equal arg "core")
do (push (expand-file-name "test/" doom-core-dir) targets) do (push (expand-file-name "test/" doom-core-dir) targets)
else else
@ -27,8 +26,8 @@ If neither is available, run all tests in all enabled modules."
(cons (intern (concat ":" car)) (cons (intern (concat ":" car))
(and cdr (intern cdr)))) (and cdr (intern cdr))))
into args into args
finally do (setq modules args finally do
command-line-args-left nil))) (setq modules args argv nil)))
(modules (modules
(unless (cl-loop for module in modules (unless (cl-loop for module in modules

View file

@ -110,10 +110,8 @@
For example, :nvi will map to (list 'normal 'visual 'insert). See For example, :nvi will map to (list 'normal 'visual 'insert). See
`doom-evil-state-alist' to customize this." `doom-evil-state-alist' to customize this."
(cl-loop for l across (substring (symbol-name keyword) 1) (cl-loop for l across (substring (symbol-name keyword) 1)
if (cdr (assq l doom-evil-state-alist)) if (cdr (assq l doom-evil-state-alist)) collect it
collect it else do (error "not a valid state: %s" l)))
else
do (error "not a valid state: %s" l)))
;; Register keywords for proper indentation (see `map!') ;; Register keywords for proper indentation (see `map!')

View file

@ -162,7 +162,8 @@ ability to invoke the debugger in debug mode."
;; reset it to a reasonable default. ;; reset it to a reasonable default.
(setq gc-cons-threshold 16777216 (setq gc-cons-threshold 16777216
gc-cons-percentage 0.1 gc-cons-percentage 0.1
file-name-handler-alist doom--file-name-handler-alist)) file-name-handler-alist doom--file-name-handler-alist)
t)
;;; ;;;

View file

@ -15,7 +15,7 @@ This module adds [[https://golang.org][Go]] support.
#+begin_quote #+begin_quote
I have mixed feelings about Go. It's a decent compromise between C and higher-level languages, is pleasantly straight-forward and elegant, but lacks /native/ support for luxuries I miss from other languages, like generics, optional arguments, and function overloading. You've got to learn to love ~interface{}~. I have mixed feelings about Go. It's a decent compromise between C and higher-level languages, is pleasantly straight-forward and elegant, but lacks /native/ support for luxuries I miss from other languages, like generics, optional arguments, and function overloading. You've got to learn to love ~interface{}~.
Still, Go has been a remarkably useful (and fast!) companion for a variety of small-to-medium backend web and CLI projects. Still, Go is a remarkably useful (and fast!) companion for a variety of small-to-medium backend web and CLI projects.
#+end_quote #+end_quote
* Table of Contents :TOC: * Table of Contents :TOC:

View file

@ -46,9 +46,9 @@
(map! :map java-mode-map (map! :map java-mode-map
:localleader :localleader
:nv "r" #'+java/refactor-menu "r" #'+java/refactor-menu
:nv "c" #'+java/compile-menu "c" #'+java/compile-menu
:nv "p" #'+java/project-menu)) "p" #'+java/project-menu))
(def-package! company-emacs-eclim (def-package! company-emacs-eclim

View file

@ -110,22 +110,22 @@ file-name => comint.el")
:group 'doom) :group 'doom)
(defface doom-modeline-buffer-path (defface doom-modeline-buffer-path
'((t (:inherit mode-line-emphasis :bold t))) '((t (:inherit (mode-line-emphasis bold))))
"Face used for the dirname part of the buffer path." "Face used for the dirname part of the buffer path."
:group '+doom-modeline) :group '+doom-modeline)
(defface doom-modeline-buffer-file (defface doom-modeline-buffer-file
'((t (:inherit mode-line-buffer-id))) '((t (:inherit (mode-line-buffer-id bold))))
"Face used for the filename part of the mode-line buffer path." "Face used for the filename part of the mode-line buffer path."
:group '+doom-modeline) :group '+doom-modeline)
(defface doom-modeline-buffer-modified (defface doom-modeline-buffer-modified
'((t (:inherit error :background nil :bold t))) '((t (:inherit (error bold) :background nil)))
"Face used for the 'unsaved' symbol in the mode-line." "Face used for the 'unsaved' symbol in the mode-line."
:group '+doom-modeline) :group '+doom-modeline)
(defface doom-modeline-buffer-major-mode (defface doom-modeline-buffer-major-mode
'((t (:inherit mode-line-emphasis :bold t))) '((t (:inherit (mode-line-emphasis bold))))
"Face used for the major-mode segment in the mode-line." "Face used for the major-mode segment in the mode-line."
:group '+doom-modeline) :group '+doom-modeline)
@ -141,17 +141,17 @@ file-name => comint.el")
:group '+doom-modeline) :group '+doom-modeline)
(defface doom-modeline-info (defface doom-modeline-info
`((t (:inherit success :bold t))) `((t (:inherit (success bold))))
"Face for info-level messages in the modeline. Used by `*vc'." "Face for info-level messages in the modeline. Used by `*vc'."
:group '+doom-modeline) :group '+doom-modeline)
(defface doom-modeline-warning (defface doom-modeline-warning
`((t (:inherit warning :bold t))) `((t (:inherit (warning bold))))
"Face for warnings in the modeline. Used by `*flycheck'" "Face for warnings in the modeline. Used by `*flycheck'"
:group '+doom-modeline) :group '+doom-modeline)
(defface doom-modeline-urgent (defface doom-modeline-urgent
`((t (:inherit error :bold t))) `((t (:inherit (error bold))))
"Face for errors in the modeline. Used by `*flycheck'" "Face for errors in the modeline. Used by `*flycheck'"
:group '+doom-modeline) :group '+doom-modeline)