Declarative home environments are pretty great. Being able to reproduce your entire user setup is fantastic when you manage multiple machines or want to make future migrations.
I run NixOS and use Home-Manager as well. This lets me define my entire system in addition to my user home contents declaratively. So with this configuration I can apply NixOS & Home-Manager to get the same results anywhere.
Where the "home config" in this case can be much more than just text files and, for example, can include the actual apps installed locally. So when you define your `.git/config` file, you can include `diff.external = ${pkgs.difft}` to refer to a locally installed version of app `difft` and home-manager does the right thing. You can also manage your user services through systemd or launchd.
Many command line programs keep their configurations somewhere under $HOME. These are often called "dotfiles".
If you ever use more than one machine, likely you'll want the same configuration available on all those machines.. so you'll want some way to copy them to a new machine.
Home Manager from the Nix community is a bit more sophisticated. It allows for writing configurations in the Nix language, which is nice if you know/like Nix. (Nix is a powerful/expressive package manager. Nix is to apt-get what vim is to notepad).
I run NixOS and use Home-Manager as well. This lets me define my entire system in addition to my user home contents declaratively. So with this configuration I can apply NixOS & Home-Manager to get the same results anywhere.
Here is an example of my Home-Manager configuration: https://github.com/jakehamilton/config/blob/a3da20eeab74a50a...
In this example I configure Git. This gets written to my user home's config directory.