Unfree software: Difference between revisions
imported>Gerg-L mNo edit summary |
imported>Hypnosis2839 m formatting |
||
Line 18: | Line 18: | ||
} | } | ||
</syntaxhighlight> | </syntaxhighlight> | ||
The previous method '''should''' work for Home-Manager standalone but is currently broken | The previous method '''should''' work for Home-Manager standalone but is currently broken. | ||
see: [https://github.com/nix-community/home-manager/issues/2942 Home-Manager Issue 2942] | see: [https://github.com/nix-community/home-manager/issues/2942 Home-Manager Issue 2942] | ||
the work-around is using: | the work-around is using: | ||
Line 30: | Line 30: | ||
=== Command Line === | === Command Line === | ||
You won't be able to install or search for an unfree package as a user, unless you explicitly enable it in | You won't be able to install or search for an unfree package as a user, unless you explicitly enable it in <code>~/.config/nixpkgs/config.nix</code> (the file and folder may need to be created): | ||
<syntaxhighlight lang="nix"> | <syntaxhighlight lang="nix"> | ||
Line 41: | Line 41: | ||
=== Temporary allowing === | === Temporary allowing === | ||
For temporary allowing unfree packages you can set the environment variable | For temporary allowing unfree packages you can set the environment variable <code>NIXPKGS_ALLOW_UNFREE</code>, e.g. | ||
<syntaxhighlight lang="bash">$ NIXPKGS_ALLOW_UNFREE=1 nix-shell</syntaxhighlight> | <syntaxhighlight lang="bash">$ NIXPKGS_ALLOW_UNFREE=1 nix-shell</syntaxhighlight> |