TL;DR: I wanna make my own home manager with blackjack and flakes
Hello, people! I am a bit confused.
Summarizing a bit: my usage of home-manager is simply install programs via home.packages list and manually edit dotfiles (I use org mode to help on it). Even when home-manager offers modules, I prefer to edit files by hand.
So my question is: how can I manage my home directory in a more handmade manner?
My idea is to use something like
$> some-nix-command my-config.nix # output: some useful directory like /nix/var/nix/profiles/per-user/<username>/...
$> edit-configuration # something like emacs .bashrc .profile .config/...
$> use-the-system
Also, I want to use as much as possible teh new flakes infrastructure, specially to get rid of NIX_PATH variable.
I was trying to follow the Matej Cotman’s article but I stuck because it uses the old Nix command.
I don’t understand what you’re trying to achieve. If you don’t want to use HM modules and instead want to write config files by hand, that’s fine, you can use home.file to have those files symlinked in place.
I don’t think you can use Flakes with it yet because the buildEnv approach (as well as the overlay approach) are based on nix-env. However, you can still use pinning to bypass Nix channels like so
let
nixexprs = fetchTarball {
url = "https://nixos.org/channels/nixos-20.09/nixexprs.tar.xz";
};
pkgs = import nixexprs { };
in with pkgs;
buildEnv {
# ...
}