Skip to content

fix: use default.nix to inject inputsOverrides if available - #22

Merged
vic merged 3 commits into
denful:mainfrom
jbgi:fix-inputsOverrides
Oct 2, 2026
Merged

vic merged 3 commits into
denful:mainfrom
jbgi:fix-inputsOverrides

Conversation

@jbgi

@jbgi jbgi commented Sep 13, 2026

Copy link
Copy Markdown
Contributor

using the flake api breaks when flakes use the following pattern:

{
    outputs = args: let f = { self }: ...; in f args;
}

(which is the case of nixpkgs-lib).

(PR based on #21 to avoid rebase)

using the flake api breaks when flakes use the following pattern:
```nix
{
    outputs = args: let f = { self }: ...; in f args;
}
```
(which is the case of nixpkgs-lib).
@jbgi
jbgi force-pushed the fix-inputsOverrides branch from 7ef6c60 to 1091bc4 Compare September 17, 2026 10:29
this avoid failing on importing default.nix in flake context.
@jbgi

jbgi commented Oct 2, 2026

Copy link
Copy Markdown
Contributor Author

@vic fixed a remaining issue in last commit, mostly for the cases where one use a with-inputs project as a flake project (eg. for template init): trying to import a default.nix input that use builtins.currentSystem was failing (eg. when it is implemented with flake-compat), so modified logic to don't try that if builtins.currentSystem is not present. Also to don't to try to import default.nix if flake.nix actually define inputs specs (more of an optimization to avoid unecessary import of default.nix).

@vic
vic merged commit e1df5e3 into denful:main Oct 2, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants