Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Improve Home Manager support: profiles/suites, modules, extern, flake outputs #156
Improve Home Manager support: profiles/suites, modules, extern, flake outputs #156
Changes from all commits
0e5aa65
416a52f
cc52cd9
dc9d987
6d51ed0
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We may need to add
inherit (config.nixpkgs) pkgs
as home-manager doesn't seem to have apkgs
argument. This may be a bug upstream however, as I believe home-manager is supposed to pass in packages. In practice though, at least with this implementation, I had to add apkgs
arg to get doom-emacs to work, for example.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are you sure thats the problem? Because home-manager already does that when
useGlobalPkgs
is true.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
" using the system configuration's pkgs
argument in Home Manager. This disables the Home Manager
options nixpkgs.*"
^ from hm nixos module
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I ran into these issues while trying to merge this into community. I just pushed the merge so you should now be able to reproduce by simply checking out the latest community branch and running
flk home NixOS nixos
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps shared modules don't get passed a
pkgs
arg, since that is how doom-emacs is entering the configuration. Not sure if this intentional by upstream or a bug. I'll search hm issue tracker to see if I can find some additional context.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could be true, I tried adding pkgs to the hm section in
users/nixos
and used it to add vim tohome.packages
and that works fine. So your theory does make sense.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In home manager, the ways pkgs is set is using
_module.args.pkgs
in home-manager/modules/modules.nix. And I wonder if doesn't get passed to modules that were imported before that. But that doesn't make sense to me, since the module system should be recursive.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe I've isolated the problem. Gonna fix and test locally then will link to an new home-manager PR if I'm correct.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
okay, I've offered a minimally invasive solution in nix-community/home-manager#1879
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hindsight review:
As it turns out, this may be a bit too aggressive. We may have to have a follow up PR to remove it, as it includes a lot of unrelated system packages and, worse, causes package conflicts in the community branch.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah thats fine we can remove that line. It worked for me and I didn't think it would cause any issues.
This file was deleted.