Commit Graph

5810 Commits

Author SHA1 Message Date
09cb4f6716 Major refactor & optimization of how modules load their packages
Now that we are loading package autoloads files (as part of the
generated doom-package-autoload-file when running make autoloads), many
:commands properties are redundant. In fact, many def-package! blocks
are redundant.

In some cases, we can do without a config.el file entirely, and can move
into the autoloads file or rely entirely on package autoloads.

Also, many settings have been moved in their module's autoloads files,
which makes them available ASAP; their use no longer depends on module
load order.

This gained me a modest ~10% boost in startup speed.
2018-05-25 00:46:16 +02:00
6a140209b8 Optimize Doom core package configs 2018-05-24 23:41:40 +02:00
9e7703db2a core-lib (add-transient-hook!): set permanent-local-hook on hook fn 2018-05-24 22:35:45 +02:00
e8653d0628 feature/file-templates: revise doom module README.org file template 2018-05-24 22:34:37 +02:00
b806ff937c feature/file-templates: rewrite & fix wrong-number-of-args errors #602 2018-05-24 22:34:37 +02:00
4c73ac0111 config/default: Fix evil-collection anti-hacks #604 2018-05-24 22:34:37 +02:00
0b48575c14 Remove def-hydra! macro alias
Causes byte-compilation issues and the alias is unnecessary.
2018-05-24 22:03:19 +02:00
7c611df6a6 Have doom//reload return t on success 2018-05-24 22:01:26 +02:00
dea7c10771 Don't do naive path concatenation for private custom-theme-directory 2018-05-24 21:20:50 +02:00
a55e2251e6 auto-mode-case-fold = nil
This disables the case insensitive second pass through auto-mode-alist
on case sensitive systems.
2018-05-24 21:20:02 +02:00
d35598520f Only package-initialize if uninitialized (from package.el API advice) 2018-05-24 21:20:02 +02:00
9e07940b7c Fix use-package autoload 2018-05-24 21:20:02 +02:00
30893b0ff1 Fix doom-initialize-packages 2018-05-24 21:20:02 +02:00
8282280965 core-packages: revise docstrings & comments 2018-05-24 21:20:02 +02:00
ea86b1075f Fix doom-template-exists-p 2018-05-24 21:20:02 +02:00
b70ed84a33 Fix doom//run-tests 2018-05-24 21:20:02 +02:00
2a8da07e31 Rename autoload-debug.el test to autoload-help.el 2018-05-24 21:20:02 +02:00
6dc375a891 Fix catch-all text-mode entry in auto-mode-alist
This indirectly fixes an issue where the elfeed db was opened in
text-mode, triggering the large-file check.
2018-05-24 21:20:02 +02:00
18a6df5e6f Fix doom/info 2018-05-24 21:20:02 +02:00
87e9365a41 Fix package autoremove/install/update batch commands 2018-05-24 21:20:02 +02:00
b629f4f507 Fix doom//clean-byte-compiled-files 2018-05-24 21:20:02 +02:00
6ea5430c4d Fix doom//byte-compile 2018-05-24 21:20:02 +02:00
3261f1fd71 Finalize core-dispatcher API
+ Add doom-auto-accept to replace YES envvar.
+ Add docstrings & documentation to all commands.
+ Make dispatcher support more than one alias.
+ Document quickstart command
+ Update autoloads/install/autoremove/update/refresh to fit new initialization workflows
+ Rename doom//info and doom//version
+ Recompile alias is now rc instead of cc
+ Improve reliability of doom//quickstart
2018-05-24 21:20:02 +02:00
8746c12fae Redesign Doom bootstrap, caching & autoload generation logic
The autoloads file has been split into doom-autoload-file and
doom-package-autoload-file. The former is for Doom's modules and
standard library; the latter is for compiling all package autoloads like
load-path and auto-mode-alist (among other things).

This reduced my startup speed from ~1s to ~0.5s
2018-05-24 21:20:02 +02:00
3dd291a675 core-lib: improve function docstrings 2018-05-24 21:15:17 +02:00
4ee0b5ba6d New macros file-exists-p! & project-file-exists-p!
The latter replaces the doom-project-has! macro
2018-05-24 21:15:17 +02:00
b2186745b7 Refactor doom--resolve-path-forms 2018-05-24 18:35:06 +02:00
47ccbb5d41 print!: use terpri instead of princ for newline
Will produce the appropriate newline for the current OS.
2018-05-24 18:30:37 +02:00
e3bdeabe0b bin/doom: discard extra command line args 2018-05-24 18:29:56 +02:00
b25e215d59 Increase last-pkg-refresh ttl from 900 -> 1200s 2018-05-24 16:41:14 +02:00
592e16d76d Conform debug commands to naming convention 2018-05-24 16:40:37 +02:00
7cfab92f7c bin/doom-doctor: refactor bash bootstrapper 2018-05-24 16:39:08 +02:00
bf3d35c287 Clean up makefile & update it to match bin/doom 2018-05-24 16:05:52 +02:00
e1e47b9173 bin/doom: minor refactor; no longer default to doom refresh
Better to be explicit, otherwise you get some weird cases where
incorrect commands fall through to a doom refresh.
2018-05-24 16:03:27 +02:00
8a7ebebf16 bin/doom: add -y/--yes option 2018-05-24 16:02:59 +02:00
499630fdcd bin/doom: handle doc/doctor especially 2018-05-24 16:00:46 +02:00
a48f75371b core-lib (doom-files-in): default relative-to to default-directory 2018-05-24 13:02:20 +02:00
5d42b1512b Fix naive path concatenation for doom-private-dir #513 2018-05-24 11:49:01 +02:00
b452aded76 Mention doom-emacs-dir must end with a slash 2018-05-24 11:44:17 +02:00
dc0175b8e1 Merge doom-files-under into doom-files-in; more powerful doom-files-in 2018-05-23 23:34:32 +02:00
2637c415d3 Add error checks & docstrings to doom-keyword-* lib functions 2018-05-23 19:09:09 +02:00
53a7e35082 lang/javascript: fix rjsx-electric-gt reparsing advice 2018-05-22 01:47:40 +02:00
8ea0f34270 doctor: update doom bootstrap logic & fix error on built-in packages 2018-05-21 18:34:33 +02:00
2e7831b8a4 doctor: reduce output for cert test 2018-05-21 18:34:33 +02:00
6a08128194 doctor: make feedback more informative 2018-05-21 18:34:33 +02:00
4e18722d49 config/default: update doom help/debug keybinds 2018-05-21 18:34:33 +02:00
af97dcdfe8 config/default: add SPC-g-o/SPC-g-I for browsing remote/issues 2018-05-21 18:34:33 +02:00
1b8dce260b config/default: restore find-in-snippets command #597
And conditionally bind snippets keybinds
2018-05-21 18:34:33 +02:00
553d00b598 Add doctor/help dummy dispatchers
This way they show up in doom help + documentation.
2018-05-21 15:42:36 +02:00
cf54b3705b bin/doom: alias h => help 2018-05-21 15:42:00 +02:00