Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flake: follow global nixpkgs #84

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

merrkry
Copy link

@merrkry merrkry commented Feb 8, 2025

Let devshell treefmt-nix hyprland home-manager follow the same global nixpkgs inputs.

By removing 4 extra nixpkgs instances, this should potentially avoid some version mismatch and accelerate evaluation.

@VTimofeenko
Copy link
Contributor

VTimofeenko commented Feb 8, 2025

Hello, and thank you for the contribution!

I am honestly a bit torn on this. Please note, that what follows is a bit of stream of consciousness and not a criticism of the PR.

Generally I am very much in favor of reusing inputs as much as possible. It does save on the evaluation time. However, it's also a signal that the flake that is overriding inputs is now responsible for ensuring that everything works.

In an ideal world, the consumers of this flake would not be retrieving the dependencies that are pinned in this PR, as they are used only for development or testing and do not affect the outputs of this flake (packages/[nixOS|homeManager]modules). I think that without lazy trees, the only way to do this today is for the consumer to override inputs they don't want.

I have been eyeing the release of 2.26 as a reason to play with the idea of splitting these inputs into an independent flake to make the inputs of the main flake as short as possible and pin nix to 2.26 in development and CI.

I also don't want perfect to be the enemy of good :)

I will bump playing with a separate dev flake closer to the head of the todo list

@merrkry
Copy link
Author

merrkry commented Feb 8, 2025

@VTimofeenko Thank you for the detailed explanation.

I am still not sure whether keeping them as-is is a good way to keep functionality, as they will still somehow be mixed up in final config. And users probably want to use follows themselves, as it's very common practice. We should try to get closer to the final result during development instead of waiting unknown changes to happen on user side. Therefore I still suggest use follows on at least home-manager (and hyprland perhaps?).

That being said, a dev flake does sound like a more comprehensive plan. It makes less sense to make changes on input when new flake structure is being worked on.

Feel free to close this.

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