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

Implement new api #264

Merged
merged 31 commits into from
Apr 27, 2021
Merged

Implement new api #264

merged 31 commits into from
Apr 27, 2021

Conversation

Pacman99
Copy link
Member

@Pacman99 Pacman99 commented Apr 26, 2021

This is the underlying implementation of the api thats defined in the new evalArgs, it drops and simplifies a lot of the code in devos.
Obsoleted by fup:

  • mkHosts => you can just pass modules, specialArgs, and builder to hostDefaults instead
  • mkPkgs => fup creates the multiPkgs and can handle applying overlays and also has the benefit of multiple channels
  • mkPackages => There is a better implementation in fup and we can now use packagesBuilder.

This includes many other changes to get to the final rebase - explanation is in commit messages.

Copy link
Contributor

@blaggacao blaggacao left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Two quick remarks, otherwise a massive improvement, we should merge roght away.

lib/devos/devosSystem.nix Show resolved Hide resolved
lib/devos/devosSystem.nix Outdated Show resolved Hide resolved
Pacman99 and others added 10 commits April 26, 2021 11:27
Get `self` and `inputs` during construction, and rely on
specialArgs.channel for nixos flake
this includes creating multiPkgs, and dropping options already set by
fup
have each function take pkgs as an argument, so a nixpkgs isn't created
just for pkgs-lib and they support more systems
Only to those with three arguments
drop default channel, it is confusing and complicates api
don't take nixos input, using channels is better
manually pass names for outputs to improve documentation
This was referenced Apr 26, 2021
Pacman99 added 12 commits April 26, 2021 18:29
to follow the new api
this makes more sense since evalArgs is the module and it makes the code
cleaner
was only meant for debugging, not meant to be commited
we need to filter out arguments that are added in the devos api
also anything thats null in either hostDefaults and hosts has to be
removed
also update overrides docs
it is a pure devos overlay now, it makes sense to go in overlays
Comment on lines +44 to +49
overlays = [
(devos.lib.pathsIn ./overlays)
./pkgs/default.nix
pkgs.overlay # for `srcs`
nur.overlay
];
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lists get flattened for overlays and modules, but not externalModules and hostDefaults.modules.

Copy link
Member Author

@Pacman99 Pacman99 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Highlighted some important parts of these changes. But overall I think its ready for final review and merge. I don't have anything else to include in here.

flake.nix Outdated Show resolved Hide resolved
lib/devos/devosSystem.nix Show resolved Hide resolved
lib/mkFlake/default.nix Show resolved Hide resolved
lib/mkFlake/default.nix Show resolved Hide resolved
overlays/overrides.nix Show resolved Hide resolved
this allows host-specific settings to be overriden with mkMerge
flake.nix Show resolved Hide resolved
Pacman99 added 2 commits April 27, 2021 12:52
lock file format isn't very reliable with naming inputs
@Pacman99 Pacman99 merged commit 62c9b12 into develop Apr 27, 2021
@bors bors bot deleted the api-next branch April 27, 2021 23:55
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