Skip to content

Commit

Permalink
Deal with agda2-mode / agda-input merge
Browse files Browse the repository at this point in the history
agda2-mode and agda-input live in the same upstream repository. Doom
handles these as separate packages (with recipes installing
agda-input.el as agda-input and everything else as agda2-mode), but
nixpkgs has just agda2-mode, with installing agda-input now triggering
an explicit error.

Work around this by by filtering out agda-input from doomPackageSet, so
we do not attempt to build/install it.

We generate packages.el one step earlier, but we want an `:ignore t`
package in there, which we also write for packages we actually install.
So this should work correctly.

Although agda-input is available as a separate package in nixpkgs 24.05,
its agda2-mode package already installs agda-input.el too. So this
change should be correct there too, even though it is not (yet)
required.

Adding a placeholder agda-input package to our elisp-packages.nix does
not work, because our repoToPins logic accesses `esuper.${name}`,
triggering the new build error.
  • Loading branch information
marienz committed Jul 20, 2024
1 parent b993c85 commit cfd7550
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,10 @@ let
scriptArgs = "-o $out";
};

doomPackageSet = lib.importJSON "${doomIntermediates}/packages.json";
# Ignore agda-input: nixpkgs installs this as part of agda2-mode.
doomPackageSet = lib.filterAttrs
(n: v: n != "agda-input")
(lib.importJSON "${doomIntermediates}/packages.json");

# Step 2: override Emacs packages to respect Doom's pins.
doomEmacsPackages = (emacsPackagesFor emacs).overrideScope (
Expand Down

0 comments on commit cfd7550

Please sign in to comment.