The init command is essentially the old install script but integrated
into the home-manager tool. This simplifies things slightly since we
can use the existing code infrastructure.
The init command is Nix flake aware in the sense that, if we detect
that the user's Nix setup supports flakes, then we also create an
initial `flake.nix` file.
Finally, we update the installation instructions for the Nix flakes
standalone setup to use the new init command.
Zsh completion update provided by Anund <anundm@gmail.com>.
This changes the default configuration location for Home Manager
configurations from
$XDG_CONFIG_HOME/nixpkgs
to
$XDG_CONFIG_HOME/home-manager
The old location is still supported but using it will trigger a
warning message.
Fixes#3640
Install home-manager via `nix run` rather than `nix-build` then running
the activation script out of the store manually.
Co-authored-by: Cédric Barreteau <cbarrete@users.noreply.github.com>
Remove `stateVersion`, `username`, and `homeDirectory` as they can be
set in the configuration directly. Together with the previous commit,
this makes setting `stateVersion` explicitly mandatory.
Also replace `configuration` by `modules`, which expects a list of
Home Manager modules.
Also remove `system` which was made useless by #3028.
In the manual:
* Add chapter Nix Flakes
* Add links to sections of chapter "Using Home Manager"
In README.md:
* Remove section "Nix Flakes"
* Add manual reference at the buttom of section "Installation"