Live data from Hacker News

Migrating from GNU Stow to Chezmoi

rednafi.com

61–70 of 152 posts

Re: Migrating from GNU Stow to Chezmoi

#63
post #28

It’s quite new but I’ve been cooking up some new bootstrapping features with mise which people may find relevant here: https://mise.jdx.dev/bootstrap.html It’s for things like dotfiles, apt/brew packages, and LaunchAgents/systemd. EDIT: I feel a little bad having hijacked this, as someone that hears a lot of opinions about devtools I can definitely say chezmoi is a darling of the community and I highly recommend chec…

I saw it the other day in the release notes and I'm definitely setting this up since I already use mise for many of my global tools and projects.

Some months ago I ported part of my git bare repo to chezmoi but never really picked it up since, even if I see it as a great and very complete tool for managing complex dotfiles, I don't have many machines and can live by with a bunch of if uname -s, and the fact that I still need to wrangle brewfiles and scripts for packages. Having the sytem package managers glue along the configs and symlinks is exactly what I wanted.

Re: Migrating from GNU Stow to Chezmoi

#64

Earlier quoted context omitted.

I am quite intrigued. With the sorry state of security, I am doing everything in VMs and have been trying to settle on the best way to setup a new machine. The process is so clunky that I end up defaulting to bigger instances than I should (more pets than cattle). Being able to centralize this config is far more attractive than having a separate Ansible or pyinfra process. Edit: The docs on this are very encouraging!…

i would reach for atomic fedora personally, maybe with bluebuild

That still feels like more external tooling, plus letting the distro make my packaging decisions. I am already using mise, so this is an almost free boon without more complexity.

Re: Migrating from GNU Stow to Chezmoi

#65
post #50

Earlier quoted context omitted.

People shy from Nix because of supposed complexity but it really is the only real solution to this sort of problem. It's not really that much more difficult to learn, and in fact if you are willing, AI works really well generating nix config.

how nix-pilled do you have to be to think that nix is the "only real solution" to dotfile managers?

"real" meaning truly reproducible and not brittle.

Re: Migrating from GNU Stow to Chezmoi

#66
post #31

Earlier quoted context omitted.

People shy from Nix because of supposed complexity but it really is the only real solution to this sort of problem. It's not really that much more difficult to learn, and in fact if you are willing, AI works really well generating nix config.

Nix's complexity isn't with itself, its if you try to step one bit off the beaten path where it immediately starts to grate.

That problem is overstated. I've been dozens of custom packages and modules and it's not that much more complex that basic Nix config, and in fact is a huge positive, not negative. How easy can you write config that packages a binary and/or sets up a new service reproducibly? I'd much rather do that on Nix than Ubuntu or Arch for sure.

Re: Migrating from GNU Stow to Chezmoi

#67
post #46
post #18

Once you hit the Chezmoi stage, you're only about 6 months from Nix and Home Manager. I mean, why climb _almost_ to the top of a mountain and then just sit down?

I ran NixOS for a while, before I switched to Apple Silicon, so I consider myself fairly well-versed-enough (although nowhere near an expert) in Nix and the Nix ecosystem. My last four jobs have all issued me MacBook Pros; the last three with Apple Silicon. Ultimately, my workplace setup is what has the most gravity. And the most I can get most workplaces to standardize on is Homebrew for package management of off-th…

So don't propose it?

You can run Nix and Home Manager on macOS or any Linux distro. You don't even need root.

It works exactly like you describe: it provides its guarantees for all software that you manage through Nix, and doesn't get in the way of software that you don't manage through Nix.

Unlike with NixOS, you can run binaries that expect an FHS-compliant system just fine.

You can just silently use it and enjoy the convenience for the declarative parts of your setup, with no detriment to your ability to run the imperative, ad-hoc setup scripts that your company requires.

Re: Migrating from GNU Stow to Chezmoi

#68

I've never really understood why people get so fancy with their setups when you can just plop a git repo into your home directory. I suspect it has to do with people being unfamiliar with git.

For me it's useful to have a separate directory with my dotfiles repo, since my dotfiles repo's top level directory doesn't correspond to my home directory. I have one subdirectory for each machine.

Re: Migrating from GNU Stow to Chezmoi

#69

I've never really understood why people get so fancy with their setups when you can just plop a git repo into your home directory. I suspect it has to do with people being unfamiliar with git.

Git works until you need conditional logic such as platform-specific files or templating.
Post reply on HN