diff --git a/index.html b/index.html index f21b8236c..c43afa7dc 100644 --- a/index.html +++ b/index.html @@ -1,6 +1,6 @@ -
ca.desrt.dconf
or dconf.service
?+
ca.desrt.dconf
or dconf.service
?+
flake.nix
as a template in ~/.config/nixpkgs
by
+$ nix flake new ~/.config/nixpkgs -t github:nix-community/home-manager
Install Home Manager and apply the configuration by
$ nix build --no-link <flake-uri>#homeConfigurations.jdoe.activationPackage $ "$(nix path-info <flake-uri>#homeConfigurations.jdoe.activationPackage)"/activate
Substitute <flake-uri>
with the flake URI of the configuration flake.
@@ -346,7 +348,7 @@ a bare-minimum flake.nix
would be as follows:
The Home Manager configuration is then part of the NixOS configuration
and is automatically rebuilt with the system when using the appropriate command
-for the system, such as nixos-rebuild switch --flake <flake-uri>
.
The flake-based setup of the Home Manager nix-darwin module
+for the system, such as nixos-rebuild switch --flake <flake-uri>
.
You can use the above flake.nix
as a template in /etc/nixos
by
$ nix flake new /etc/nixos -t github:nix-community/home-manager#nixos
The flake-based setup of the Home Manager nix-darwin module
is similar to that of NixOS. The flake.nix
would be:
{
description = "NixOS configuration";
@@ -378,7 +380,7 @@ is similar to that of NixOS. The flake.nix
would be
};
};
}
and it is also rebuilt with the nix-darwin generations.
-The rebuild command here may be darwin-rebuild switch --flake <flake-uri>
.
The module system in Home Manager is based entirely on the NixOS module system so we will here only highlight aspects that are specific for Home Manager. For information about the module system as such please refer to the Writing NixOS Modules chapter of the NixOS manual.
Overall the basic option types are the same in Home Manager as NixOS. A few Home Manager options, however, make use of custom types that are worth describing in more detail. These are the option types dagOf
and gvariant
that are used, for example, by programs.ssh.matchBlocks
and dconf.settings
.
darwin-rebuild switch --flake <flake-uri>
.You can use the above flake.nix
as a template in ~/.config/darwin
by
$ nix flake new ~/.config/darwin -t github:nix-community/home-manager#nix-darwin
The module system in Home Manager is based entirely on the NixOS module system so we will here only highlight aspects that are specific for Home Manager. For information about the module system as such please refer to the Writing NixOS Modules chapter of the NixOS manual.
Overall the basic option types are the same in Home Manager as NixOS. A few Home Manager options, however, make use of custom types that are worth describing in more detail. These are the option types dagOf
and gvariant
that are used, for example, by programs.ssh.matchBlocks
and dconf.settings
.
hm.types.dagOf
Options of this type have attribute sets as values where each member is a node in a directed acyclic graph (DAG). This allows the attribute set entries to express dependency relations among themselves. This can, for example, be used to control the order of match blocks in a OpenSSH client configuration or the order of activation script blocks in home.activation
.
diff --git a/tools.html b/tools.html
index 088857e31..94f53aed1 100644
--- a/tools.html
+++ b/tools.html
@@ -1,6 +1,6 @@
-
home-manager +
home-manager — reconfigure a user environment
home-manager
{
build
|
@@ -84,7 +84,7 @@
|
--verbose
}
- ]
This command updates the user environment so that it corresponds to the
configuration specified in ~/.config/nixpkgs/home.nix
or ~/.config/nixpkgs/flake.nix
.
@@ -153,7 +153,7 @@ available for immediate garbage collection.
-
The tool accepts the options
-A attrPath
@@ -265,15 +265,15 @@
--verbose
Activates verbose output. -