move config to better places

This commit is contained in:
Vinzenz Schroeter 2023-09-24 13:04:45 +02:00
parent ddb7df4a4e
commit 9b60bc1988
4 changed files with 53 additions and 51 deletions

View file

@ -4,7 +4,7 @@
lib,
...
}: let
cfg = config.my.desktop;
isEnabled = config.my.desktop.enable;
in {
imports = [
./gnome.nix
@ -14,10 +14,7 @@ in {
options.my.desktop.enable = lib.mkEnableOption "desktop";
config = lib.mkIf cfg.enable {
home-manager.useUserPackages = true;
home-manager.useGlobalPkgs = true;
config = lib.mkIf isEnabled {
services = {
# Enable the X11 windowing system / wayland depending on DE
xserver.enable = true;
@ -49,11 +46,6 @@ in {
programs = {
git.package = pkgs.gitFull;
steam = {
enable = true;
remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play
dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server
};
};
# unblock kde connect / gsconnect
@ -89,8 +81,6 @@ in {
};
environment = {
pathsToLink = ["/share/zsh"];
systemPackages = with pkgs; [
lm_sensors
];

View file

@ -17,7 +17,6 @@ in {
wineWowPackages.stagingFull
wineWowPackages.fonts
winetricks
steam
(lutris.override {
extraPkgs = pkgs: [
@ -28,5 +27,13 @@ in {
];
})
];
programs = {
steam = {
enable = true;
remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play
dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server
};
};
};
}

View file

@ -23,47 +23,51 @@ in {
];
config = lib.mkIf enableHomeManager {
home-manager.sharedModules = [
# set stateVersion
{home.stateVersion = "22.11";}
# make nano the default editor
{
home = {
sessionVariables.EDITOR = "nano";
file.".nanorc".text = lib.mkDefault ''
set linenumbers
set mouse
'';
};
}
# command line niceness
{
programs = {
command-not-found.enable = true;
dircolors.enable = true;
home-manager = {
useUserPackages = true;
useGlobalPkgs = true;
sharedModules = [
# set stateVersion
{home.stateVersion = "22.11";}
# make nano the default editor
{
home = {
sessionVariables.EDITOR = "nano";
file.".nanorc".text = lib.mkDefault ''
set linenumbers
set mouse
'';
};
}
# command line niceness
{
programs = {
command-not-found.enable = true;
dircolors.enable = true;
zsh = {
enable = true;
enableSyntaxHighlighting = true;
enableAutosuggestions = true;
enableVteIntegration = true;
};
};
}
# common git config
{
programs = {
git = {
enable = true;
extraConfig.init.defaultBranch = "main";
zsh = {
enable = true;
enableSyntaxHighlighting = true;
enableAutosuggestions = true;
enableVteIntegration = true;
};
};
}
# common git config
{
programs = {
git = {
enable = true;
extraConfig.init.defaultBranch = "main";
};
gh = {
enable = true;
enableGitCredentialHelper = true;
gh = {
enable = true;
enableGitCredentialHelper = true;
};
};
};
}
];
}
];
};
};
}

View file

@ -70,6 +70,7 @@
aliases = {
prettylog = "log --pretty=oneline --graph";
spring-clean = "!git branch --merged | xargs -n 1 -r git branch -d";
};
extraConfig = {