vimjoyer / flake-starter-config

The Unlicense
89 stars 10 forks source link

error: cannot look up '<nixos-hardware/tuxedo/infinitybook/pro14/gen7>' in pure evaluation mode (use '--impure' to override) #8

Open cig0 opened 2 months ago

cig0 commented 2 months ago

Hi all,

While following the tutorial "Ultimate NixOS Guide | Flakes | Home Manager", I stumbled upon that issue when trying to perform a system update, as instructed in the tutorial: doas nixos-rebuild switch --flake /etc/nixos#default

As the error says, I'm importing a hardware module for my laptop:

  imports =
    [ # Include the results of the hardware scan.
      ./hardware-configuration.nix
      # Additional hardware settings
      <nixos-hardware/tuxedo/infinitybook/pro14/gen7>

In this case, this module is pretty simple, so I could directly import the kernel arguments into my configuration, but being new to NixOS, I'd gladly appreciate it if anyone could give me more context about:

  1. Why this action is failing
  2. What would be the right way to proceed (read: best practices)
  3. What would be the implications of enabling the --impure flag to allow the evaluation

Thanks!