this post was submitted on 18 Jul 2023
668 points (92.7% liked)

Memes

45731 readers
1408 users here now

Rules:

  1. Be civil and nice.
  2. Try not to excessively repost, as a rule of thumb, wait at least 2 months to do it if you have to.

founded 5 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] pimeys@lemmy.nauk.io 14 points 1 year ago (2 children)

Just casually having Firefox with plugins and settings described in my NixOS config.

https://github.com/pimeys/nixos/blob/main/desktop/firefox/default.nix

Works always the same.

[–] nosurf@unilem.org 2 points 1 year ago (2 children)

Man nix looks soo damn cool. I just dont know if id ever actually use it. But a versioned controlled OS seems so sweet.

Can you use it to choose desktop environment as well?

[–] pimeys@lemmy.nauk.io 2 points 1 year ago

You can. I run sway and it is configured through nix:

https://github.com/pimeys/nixos/blob/main/desktop/sway/default.nix

Gnome design makes it a bit harder, but not impossible:

https://hoverbear.org/blog/declarative-gnome-configuration-in-nixos/

Somebody doing the same for KDE:

https://github.com/LunNova/nixos-configs/blob/dev/users/lun/on-nixos/kdeconfig.nix

So the answer to your question is yes. It is possible and kind of required to go the full nix route with NixOS. It might not always be super straightforward with large DEs, and for sure works much better with window managers that already utilize text configuration.

[–] Xylight@lemmy.xylight.dev 1 points 1 year ago (2 children)

Yep. To change desktop environments, just change:

services.xserver.gnome.enable = true;

to

services.xserver.plasma5.enable = true;
[–] nosurf@unilem.org 1 points 1 year ago (1 children)

Wow. Im gonna try it out in a vm even if i have no use for it. That is crazy.

[–] Xylight@lemmy.xylight.dev 2 points 1 year ago (1 children)

It's really nice. When you setup a new system, you don't have to spend hours changing settings, configs, and installing packages. With NixOS, just copy the config file from your old system and then run nixos-rebuild.

[–] pimeys@lemmy.nauk.io 1 points 1 year ago

I really wish the default template switches to flakes soon. Using flakes is a must for the best experience, and converting the default config is at best a hassle and for newbies a huge mountain to cross.

[–] pimeys@lemmy.nauk.io 1 points 1 year ago

This is cool because it gets rid of all the packages when you switch. There is nothing left of Gnome when you switch to KDE.

[–] HappyFrog@lemmy.blahaj.zone 2 points 1 year ago

Damn, nix is starting to look better each time I hear about it.