mirror of
https://github.com/nix-community/nix-doom-emacs
synced 2025-09-14 15:46:58 -05:00
Overlay support for emacs (elisp) dependencies
This is needed as custom packages may need the same treatment as built-in dependencies of doom. See `./overrides.nix` for details. The `bundledPackages` option may be consolidated to use this argument as well in the future. References: #55
This commit is contained in:
15
default.nix
15
default.nix
@@ -24,6 +24,18 @@
|
|||||||
Only used to get emacs package, if `bundledPackages` is set.
|
Only used to get emacs package, if `bundledPackages` is set.
|
||||||
*/
|
*/
|
||||||
, emacsPackages
|
, emacsPackages
|
||||||
|
/* Overlay to customize emacs (elisp) dependencies
|
||||||
|
|
||||||
|
See overrides.nix for addition examples.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
emacsPackagesOverlay = self: super: {
|
||||||
|
magit-delta = super.magit-delta.overrideAttrs (esuper: {
|
||||||
|
buildInputs = esuper.buildInputs ++ [ pkgs.git ];
|
||||||
|
});
|
||||||
|
};
|
||||||
|
*/
|
||||||
|
, emacsPackagesOverlay ? self: super: { }
|
||||||
/* Use bundled revision of github.com/nix-community/emacs-overlay
|
/* Use bundled revision of github.com/nix-community/emacs-overlay
|
||||||
as `emacsPackages`.
|
as `emacsPackages`.
|
||||||
*/
|
*/
|
||||||
@@ -59,7 +71,8 @@ let
|
|||||||
then dependencyOverrides.${p}
|
then dependencyOverrides.${p}
|
||||||
else sources.${p};
|
else sources.${p};
|
||||||
# Packages we need to get the default doom configuration run
|
# Packages we need to get the default doom configuration run
|
||||||
overrides = pkgs.callPackage ./overrides.nix { inherit lock; };
|
overrides = self: super:
|
||||||
|
(pkgs.callPackage ./overrides.nix { inherit lock; } self super) // (emacsPackagesOverlay self super);
|
||||||
|
|
||||||
# Stage 1: prepare source for byte-compilation
|
# Stage 1: prepare source for byte-compilation
|
||||||
doomSrc = stdenv.mkDerivation {
|
doomSrc = stdenv.mkDerivation {
|
||||||
|
Reference in New Issue
Block a user