Commit graph

208 commits

Author SHA1 Message Date
Henrik Lissner
7e87ab3e29
New warn! macro; replace debug! with log! macro 2018-02-04 17:53:31 -05:00
Henrik Lissner
2734810060
Show error when looking up dependency trees for built-in packages
There's no obvious way to do this, and I don't think it's important
enough to accommodate it.
2018-01-07 00:15:58 -05:00
Henrik Lissner
392f04446f
General refactor (use map.el more)
+ map-delete is shorter and faster than assq-delete-all
+ map-put is simpler than the delete-then-set workflow
+ map-merge is great for merging default and user settings
2018-01-07 00:15:58 -05:00
Henrik Lissner
31a4244686
Rethink what Doom loads at startup and manually
Better to simply load what we need, when we need it, rather than set up
autoloads for every litte thing.
2018-01-07 00:15:57 -05:00
Henrik Lissner
0042a56d02
Add new cache library (persistent-soft wrapper) 2018-01-07 00:15:57 -05:00
Henrik Lissner
5d186d10b4
doom-install-package: don't try to uninstall built-in packages 2018-01-04 16:16:45 -05:00
Henrik Lissner
f3bad40fdf
Packages api: simpler error handling 2018-01-04 16:16:45 -05:00
Henrik Lissner
a29bc54c63
Install packages in the order they are declared 2018-01-04 16:16:45 -05:00
Henrik Lissner
7ab8958971
Refactor package management api + remove doom-initialize 2017-12-22 16:26:08 -05:00
Henrik Lissner
98e324b785
Fix 'not installed' errors for built-in packages #288
Caused by doom-package-backend not taking into account that a package
could be built-in. Derp!
2017-12-22 04:02:58 -05:00
Henrik Lissner
34c74d2d5c
doom//packages-install: fix skipped cleanup code 2017-12-20 20:10:14 -05:00
Henrik Lissner
4e83cd516c
Add unicode symbols to package management output 2017-12-20 20:07:46 -05:00
Henrik Lissner
76a4ae459d
Fix obsolete (when|if)-let messages in Emacs 26 2017-12-10 14:49:52 -05:00
Henrik Lissner
6def061c5a
Minor refactor/comment corrections 2017-11-13 18:03:36 +01:00
Henrik Lissner
958c7da288
Fix ALREADY INSTALLED for packages with new backends #222 2017-11-13 18:02:57 +01:00
Henrik Lissner
80d8949f91
doom-update-package: error if package's backend has changed 2017-11-13 18:01:38 +01:00
Henrik Lissner
cc3f2c76d9
doom-install-package: let -> let* 2017-11-13 18:00:46 +01:00
Henrik Lissner
eb01401513
Remove references to old package api 2017-11-13 17:58:16 +01:00
Henrik Lissner
903ac3f0ef
Run doom//reload-autoloads in separate session
Includes a minor refactor core/core-packages.el
2017-11-08 22:51:55 +01:00
Henrik Lissner
0c2b1b5a93
Fix packages with changed backend #222
Doom can't tell what backend a package was installed with, only whether it
is installed or not. This means if a package was installed with, say,
ELPA, then was changed to QUELPA, Doom wouldn't know.

Package management would fail. ELPA/QUELPA can't manage a package that
it didn't install.

This fix gives Doom that capability.
2017-11-05 19:54:43 +01:00
Henrik Lissner
95a5b46dc5
New // naming convention + refactor doom management functions 2017-11-05 19:54:43 +01:00
Henrik Lissner
43a9acec28
Simplify doom-get-outdated-packages (1 thread per quelpa pkg) 2017-11-05 19:54:43 +01:00
Henrik Lissner
42fec8494d
Rename doom/reload => doom/reload-load-path 2017-09-19 15:07:57 +02:00
Henrik Lissner
81c54684de
Fix incorrect user-emacs-directory when updating packages #190 2017-09-05 12:40:54 +02:00
Henrik Lissner
85c28444b3
General cleanup & refactor 2017-08-06 16:30:53 +02:00
Henrik Lissner
59544391f2
Refactor doom-get-packages
Adds an INSTALLED-ONLY-P argument to doom-get-packages.

Fixes a missing-package error when doom-get-outdated-packages iterates
over packages that aren't installed.

Plus, updated unit tests.
2017-07-14 15:16:32 +02:00
Henrik Lissner
ed1a79040e
Revert async package refresh
Unnecessary complexity for negligible gain.
2017-07-04 12:26:34 +02:00
Henrik Lissner
a002f7025c
Rewrite docstrings for package functions/macros 2017-07-02 16:47:27 +02:00
Henrik Lissner
76b020eddb
package management: change output on retry/errors 2017-06-28 15:33:19 +02:00
Henrik Lissner
822c78554f
destructuring-bind => cl-destructuring-bind 2017-06-25 02:04:50 +02:00
Henrik Lissner
83f4f2e725 Remove s.el dependency in doom/packages-update 2017-06-24 02:25:15 +02:00
Henrik Lissner
e2c161cbf8 Clean up doom-get-outdated-packages 2017-06-24 02:25:15 +02:00
Henrik Lissner
ee1fb43b93
Make doom-get-outdated-packages asynchronous 2017-06-21 16:09:58 +02:00
Henrik Lissner
cacd188286
Replace doom-package-*-p with doom-package-prop 2017-06-14 21:15:19 +02:00
Henrik Lissner
732dee608a
Stability/error-handling refactor (part 1)
This refactor is about improving how Emacs deals with errors.

A large net is now cast at startup to catch possible errors, produce
more helpful error messages, and localize the damage. Significantly
reducing the risk of later modules not loading (and leaving you
stranded in a half-broken Emacs session).

The DOOM core files are an exception. If something messes up in there,
it *should* choke.

+ use-package will now report missing packages or slow-loading/broken
  def-package! configurations.
+ Persp-mode no longer (inadvertantly) hides buffers that pop up at
  startup, like the *Warnings*, *Backtrace* or debugger buffers.
+ `make autoloads` (or doom/reload-autoloads) now produces a slightly
  more informative error message if an error occurs while building the
  autoloads file.
+ Error handling for package management is *slightly* better now; error
  messages now include the type of error; this needs work.
2017-06-14 21:15:19 +02:00
Henrik Lissner
7c20a43be6
Clean up quelpa build repos on package deletion 2017-06-10 23:32:59 +02:00
Henrik Lissner
c7254e7bdc
Major optimization refactor, across the board
+ enable lexical-scope everywhere (lexical-binding = t): ~5-10% faster
  startup; ~5-20% general boost
+ reduce consing, function calls & garbage collection by preferring
  cl-loop & dolist over lambda closures (for mapc[ar], add-hook, and
  various cl-lib filter/map/reduce functions) -- where possible
+ prefer functions with dedicated opcodes, like assq (see byte-defop's
  in bytecomp.el for more)
+ prefer pcase & cond (faster) over cl-case
+ general refactor for code readability
+ ensure naming & style conventions are adhered to
+ appease byte-compiler by marking unused variables with underscore
+ defer minor mode activation to after-init, emacs-startup or
  window-setup hooks; a customization opportunity for users + ensures
  custom functionality won't interfere with startup.
2017-06-09 00:47:45 +02:00
Henrik Lissner
a2f14183a1
Fix double package-refresh on first install 2017-06-06 12:01:10 +02:00
Henrik Lissner
27bfa14def General refactor + cleanup 2017-06-05 14:23:17 +02:00
Henrik Lissner
435fda0f41
Add :ignore & :freeze support to package! 2017-06-05 14:21:07 +02:00
Henrik Lissner
e8a94535da Fix package update not deleting old folder 2017-06-05 12:35:51 +02:00
Henrik Lissner
1c6ecc660a Improve package management feedback
With quelpa updating fixed, there is a longer delay on package update.
So I added a 'looking for outdated packages...' message, and improved
the formatting of backtraces in debug output.
2017-06-03 21:31:16 +02:00
Henrik Lissner
ca96b0d9c5 Fix wrong-type-argument on quelpa package update 2017-06-03 21:30:41 +02:00
Henrik Lissner
09ec857c60 Fix outdated quelpa package detection 2017-06-03 21:29:33 +02:00
Henrik Lissner
6807a5fda8 Rewrite how doom-update-package updates from ELPA
This is an attempt to make package updating atomic. Previously, if
a package failed to update, it would've been deleted.
2017-06-03 21:01:32 +02:00
Henrik Lissner
45627d6ea6 Initialize more state for package management fns 2017-06-03 12:05:43 +02:00
Henrik Lissner
e4a6780775 How did I miss this mistake?! Argh!
Must've slipped through during one of a 4am debugging session.
2017-06-03 12:05:43 +02:00
Henrik Lissner
29091c40ad Refactor doom-refresh-packages (and make it async) 2017-05-28 02:48:20 +02:00
Henrik Lissner
42a63c661b Use persistent-soft's native TTL expiration
Don't need to reinvent the wheel.
2017-05-26 20:22:45 +02:00
Henrik Lissner
8615bf23ca Move doom/am-i-secure to autoload/debug 2017-05-26 20:22:45 +02:00