Tags : Mobile edit Mobile web edit
Line 1:
Line 1:
<ol style="list-style-type: decimal;">
Create a meta package called ''userPackages'' your ''~/.config/nixpkgs/config.nix'' file with the packages you would like to have in your environment:
<li><p>Create a meta package called ''userPackages'' your ''~/.config/nixpkgs/config.nix'' file with the packages you would like to have in your environment:</p>
<syntaxhighlight lang="nix">
with (import <nixpkgs> {});
{
packageOverrides = pkgs: with pkgs; {
userPackages = buildEnv {
inherit ((import <nixpkgs/nixos> {}).config.system.path)
pathsToLink ignoreCollisions postBuild;
extraOutputsToInstall = [ "man" ];
name = "user-packages";
paths = [ vim git wget ];
};
};
}
</syntaxhighlight></li>
<li><p>Install all specified packages using this command:</p>
<syntaxhighlight lang="bash">nix-env -iA userPackages -f '<nixpkgs>'</syntaxhighlight></li></ol>
Latest revision as of 15:43, 10 October 2025
Message definition (FAQ ) Create a meta package called ''userPackages'' your ''~/.config/nixpkgs/config.nix'' file with the packages you would like to have in your environment:
Create a meta package called userPackages your ~/.config/nixpkgs/config.nix file with the packages you would like to have in your environment: