From 0dfe1bc3d5a34ce517c1fe2d7c19d697f00a699b Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Tue, 15 May 2018 23:11:48 +0200 Subject: [PATCH] Allow chained package!'s This allows users to disable one master package, thus disabling all its children. e.g. Disable irony, then irony-eldoc, flycheck-irony, company-irony and company-irony-c-headers will be disabled too. --- core/core-packages.el | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/core/core-packages.el b/core/core-packages.el index 8330863f0..b053356cc 100644 --- a/core/core-packages.el +++ b/core/core-packages.el @@ -597,7 +597,10 @@ Accepts the following properties: :ignore FORM Do not install this package. :freeze FORM - Do not update this package if FORM is non-nil." + Do not update this package if FORM is non-nil. + +Returns t if package is successfully registered, and nil if it was disabled +elsewhere." (declare (indent defun)) (doom--assert-stage-p 'packages #'package!) (cond ((memq name doom-disabled-packages) nil) @@ -623,7 +626,8 @@ Accepts the following properties: `(progn ,(when (and pkg-pin t) `(map-put package-pinned-packages ',name ,pkg-pin)) - (map-put doom-packages ',name ',plist)))))) + (map-put doom-packages ',name ',plist) + t))))) (defmacro packages! (&rest packages) "A convenience macro like `package!', but allows you to declare multiple