From 83302a46adf67b80e08fbf5267a5b05c17dc42f2 Mon Sep 17 00:00:00 2001 From: Marien Zwart Date: Wed, 22 May 2024 23:39:22 +1000 Subject: [PATCH 1/2] Add two more emacsattic packages (used by scala) We need better test coverage to figure out how many more of these there are. I don't see a way of dealing with them better, but (unless they are revived) they should not change underneath us, so keeping these overrides does not seem too risky. Fix formatting for the sly-stepper pin while I'm there. --- fetch-overrides.nix | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/fetch-overrides.nix b/fetch-overrides.nix index 362a3f9..6fd7e3d 100644 --- a/fetch-overrides.nix +++ b/fetch-overrides.nix @@ -19,7 +19,10 @@ font-lock-ext = "https://github.com/sensorflo/font-lock-ext.git"; sln-mode = "https://github.com/sensorflo/sln-mode.git"; # Straight recipe from emacsmirror-mirror + # (emacsmirror-mirror includes emacsattic, emacs-overlay does not...) nose = "https://github.com/emacsattic/nose.git"; + ob-ammonite = "https://github.com/emacsattic/ob-ammonite.git"; + ammonite-term-repl = "https://github.com/emacsattic/ammonite-term-repl.git"; # In nixpkgs, but uses codeberg, for which nixpkgs uses fetchzip. # TODO: consider parsing origEPkg.src.url instead. tree-sitter-indent = "https://codeberg.org/FelipeLema/tree-sitter-indent.el.git"; @@ -32,7 +35,9 @@ # Pins for packages not pinned by Doom and not in nixpkgs or emacs-overlay. extraPins = { # Looks stable enough we can get away with pinning it. - "sly-stepper" = "da84e3bba8466c2290c2dc7c27d7f4c48c27b39e"; + sly-stepper = "da84e3bba8466c2290c2dc7c27d7f4c48c27b39e"; + # In emacsattic, so shouldn't change underneath us. + ammonite-term-repl = "b552fe21977e005c1c460bf6607557e67241a6b6"; }; # TODO figure out whether we're better off always setting allRefs. From 4cf47c2fa746dd806bd475cdd1bb2c3b44d1a92f Mon Sep 17 00:00:00 2001 From: Marien Zwart Date: Wed, 22 May 2024 23:41:07 +1000 Subject: [PATCH 2/2] Fix dependencies on unknown packages Triggered by ob-ammonite (used by scala, in emacsattic) depending on ammonite-term-repl (also in emacsattic). `eself` only contains emacs-overlay and doomPackageSet. All of this needs refactoring, but an explicit recursive call fixes the immediate problem. --- default.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/default.nix b/default.nix index 188f0fd..407e89f 100644 --- a/default.nix +++ b/default.nix @@ -219,7 +219,9 @@ let recipe = writeText "${name}-generated-recipe" '' (${name} :fetcher github :repo "marienz/made-up" ${optionalString (p ? recipe.files) ":files ${p.recipe.files}"})''; - packageRequires = map (name: eself.${name}) reqlist; + # TODO: refactor out the recursive call to makePackage. + # (Currently needed for dependencies on packages not in epkgs or doom.) + packageRequires = map (name: eself.${name} or (makePackage name {})) reqlist; } else origEPkg); url =