this post was submitted on 12 Apr 2025
23 points (100.0% liked)

Nix / NixOS

2115 readers
33 users here now

Main links

Videos

founded 2 years ago
MODERATORS
 

Hello!

I'm getting back into NixOS again and i want to refactor my config heavily. Does anyone have any tips, advice or criticism on it? TIA.

https://codeberg.org/fxomt/nixos

top 11 comments
sorted by: hot top controversial new old
[–] [email protected] 1 points 9 hours ago

Only fair that i share my abomination


TODO Theming

Have a look at stylix (my settings uses this module)

[–] [email protected] 6 points 18 hours ago* (last edited 13 hours ago) (2 children)

Very exciting! You're layout looks fine as is. As it grows it might change, but for what you have now its a great schema.

On themes: catppuccin has a dedicated flake for applying the catppuccin style to a lot of different terminal apps and gnome/kde I think. I prefer this over stylix, a general purpose themer, because I want explicit control over which color scheme is enabled on each app. Stylix is cool, but doesnt make it easy (or possible?) to apply different themes to different apps.

Declarative flatpak by ~~germanbread~~ in-a-dil-emma is a nice flake. Occassionally theres a flatpak I need that isnt already packaged. This takes care of that. https://github.com/in-a-dil-emma/declarative-flatpak

If you want to work with secrets, look into sops-nix. Vimjoyer on youtube has a great video on how to get it setup.

[–] [email protected] 1 points 14 hours ago (1 children)

Thanks! :D Tbh i'm not quite sure what i'd store as a secret, but I still want to implement it when i need it later. I definitely want to set up nix-flatpak since some games i use are only on there, but i'm working on that.

[–] [email protected] 1 points 13 hours ago

I enjoy beyond all reason, which is the only flatpak I have in my config XD

[–] [email protected] 1 points 15 hours ago (1 children)

Can you link the go repo for declarative flatpak because I can’t quiet find it

[–] [email protected] 1 points 13 hours ago* (last edited 13 hours ago)

It appears the original user changed their github username. The project now lives at https://github.com/in-a-dil-emma/declarative-flatpak

[–] [email protected] 4 points 22 hours ago (1 children)

I’m just starting with Nix I’m going to study this XD

[–] [email protected] 1 points 22 hours ago

:) feel free to, though keep in mind it's a WIP and might not have best practices.

[–] [email protected] 2 points 21 hours ago (1 children)

I appreciate the way you did things. Here is mine. Mine is a bit more hierarchical, and bit more abstracted (especially in the flake), but I wouldn't say one way is better than another.

https://codeberg.org/jevans/nix-config

[–] [email protected] 6 points 20 hours ago (1 children)

Thanks :)

From your config:

    # proton GE needs to be installed imperatively using protonup

    environment.sessionVariables = {
      STEAM_EXTRA_COMPAT_TOOLS_PATHS = "/home/${config.globalConfig.user}/.steam/root/compatibilitytools.d";
    };

This is not the case anymore, there's now a proton-ge package. Mine is:

  programs.steam = {
    inherit (cfg) enable;

    extraCompatPackages = with pkgs; [proton-ge-bin];

    remotePlay.openFirewall = true;
    dedicatedServer.openFirewall = true;
  };

I'll take a deeper look into your config later, it seems quite nice, i could learn something from it.

[–] [email protected] 1 points 10 hours ago

ooo thanks! I haven't looked into that in a while