Doesn't manage to import file.nix in pure mode

I am getting this eror when executing home-manager switch : It is because when i try to import something i can’t get it to work.

Here is my config :
https://github.com/aurreland/nixos-config

The problem is in home-manager/home.nix
When putting it in absolute path it works but not in relative

Flakes currently copy files to Nix store before evaluating them (notice that the error happens in /nix/store/…-source/home-manager/home.nix). In git repositories, only files that git is aware of are copied though so you will need to ensure that. No need to go all in and commit the file or even just stage it with git add, registering it with git add --intent-to-add home-manager/xdg-config.nix will be sufficient.

After that, it should work in pure evaluation.

1 Like

Thanks I dindn’t that i needed to add a file with git but i guess it makes total sense. Now It works perfectly thx !