You are viewing a single thread.
View all comments
7 points

Just use NixOS. Not minimalist but very organized and feels comfortable

permalink
report
reply
1 point

You can use Nix outside of NixOS. Nix + Void has been the mainstay for my machines for the past couple of years.

permalink
report
parent
reply
0 points

Right now I have a VM running NixOS, so I can figure things out. What annoys me is that when asked to list all the programs I want to use, I struggle, but installing things on the fly is so much more easier. Nix-env does that, but it doesn’t add it to a /etc/nixos/configuration.nix, does it? Also, I know about home-manager, but I’ve heard it’s extrememly difficult.

permalink
report
parent
reply
4 points
*

No, nix-env installs to your user environment, which the nixos-rebuild command barely touches. It doesn’t touch the global configuration file. In fact you can even manage user accounts imperatively.

My approach is the following: try a program using nix run (or nix-shell, depending on the case) and if it does what I want, add it to my configuration and nixos-rebuild test. It will then be available permanently on next update.

What I also do is keep all nix-related files in a git repository under main user control and have the flake.nix (if using flakes, otherwise configuration.nix) soft linked into /etc/nixos. This also enables rollback on your configuration, not only on the actual system state.

I agree that each package takes more time, but OTOH, you save a lot of time and effort in the longer run. Also I don’t really have that high fluctuation of packages that it actually matters.

home-manager is a bit in a weird spot in my opinion as in it’s not very clear how it should be installed. If it’s a NixOS module, your changes will only be applied during rebuild - which only root can trigger. But if you’re already triggering those as root, you might as well as the packages globally. I generally install globally and configure the options using home-manager.

permalink
report
parent
reply
0 points

Sounds great, but I don’t like editing a config file every time I want to install an app,.

permalink
report
parent
reply

linuxmemes

!linuxmemes@lemmy.world

Create post

I use Arch btw


Sister communities:
Community rules
  1. Follow the site-wide rules and code of conduct
  2. Be civil
  3. Post Linux-related content
  4. No recent reposts

Please report posts and comments that break these rules!

Community stats

  • 7.7K

    Monthly active users

  • 1.3K

    Posts

  • 69K

    Comments