From 39dd3f47c837aad973b13b6ee805a480b8ca456f Mon Sep 17 00:00:00 2001 From: Jo Date: Thu, 25 Apr 2024 02:33:53 +0200 Subject: [PATCH] We do a little refactoring + plasma theming --- .gitignore | 2 + .idea/.gitignore | 8 + .idea/material_theme_project_new.xml | 12 ++ .idea/modules.xml | 8 + .idea/nix-config.iml | 8 + .idea/php.xml | 19 ++ .idea/vcs.xml | 6 + README.md | 1 - flake.lock | 174 +++--------------- flake.nix | 67 +++---- home-manager/home.nix | 132 ------------- home-manager/puzzlevision/home.nix | 55 ++++++ hosts/lenovo-pc/hardware.nix | 0 .../puzzlevision}/configuration.nix | 65 +++---- .../puzzlevision}/hardware-configuration.nix | 25 ++- modules/home-manager/default.nix | 6 + .../themes/qt_catppuccin-macchiato.nix | 1 + modules/nixos/default.nix | 6 + .../nixos}/desktop/gnome.nix | 8 +- modules/nixos/desktop/kde.nix | 19 ++ nixos/modules/desktop/kde.nix | 27 --- pkgs/default.nix | 5 + 22 files changed, 257 insertions(+), 397 deletions(-) create mode 100644 .idea/.gitignore create mode 100644 .idea/material_theme_project_new.xml create mode 100644 .idea/modules.xml create mode 100644 .idea/nix-config.iml create mode 100644 .idea/php.xml create mode 100644 .idea/vcs.xml delete mode 100644 home-manager/home.nix create mode 100644 home-manager/puzzlevision/home.nix delete mode 100644 hosts/lenovo-pc/hardware.nix rename {nixos => hosts/puzzlevision}/configuration.nix (77%) rename {nixos => hosts/puzzlevision}/hardware-configuration.nix (63%) create mode 100644 modules/home-manager/default.nix create mode 100644 modules/home-manager/themes/qt_catppuccin-macchiato.nix create mode 100644 modules/nixos/default.nix rename {nixos/modules => modules/nixos}/desktop/gnome.nix (73%) create mode 100644 modules/nixos/desktop/kde.nix delete mode 100644 nixos/modules/desktop/kde.nix create mode 100644 pkgs/default.nix diff --git a/.gitignore b/.gitignore index e69de29..511d463 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1,2 @@ +# Jetbrains configuration directory +/.idea diff --git a/.idea/.gitignore b/.idea/.gitignore new file mode 100644 index 0000000..13566b8 --- /dev/null +++ b/.idea/.gitignore @@ -0,0 +1,8 @@ +# Default ignored files +/shelf/ +/workspace.xml +# Editor-based HTTP Client requests +/httpRequests/ +# Datasource local storage ignored files +/dataSources/ +/dataSources.local.xml diff --git a/.idea/material_theme_project_new.xml b/.idea/material_theme_project_new.xml new file mode 100644 index 0000000..bf4105a --- /dev/null +++ b/.idea/material_theme_project_new.xml @@ -0,0 +1,12 @@ + + + + + + \ No newline at end of file diff --git a/.idea/modules.xml b/.idea/modules.xml new file mode 100644 index 0000000..826940c --- /dev/null +++ b/.idea/modules.xml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/nix-config.iml b/.idea/nix-config.iml new file mode 100644 index 0000000..c956989 --- /dev/null +++ b/.idea/nix-config.iml @@ -0,0 +1,8 @@ + + + + + + + + \ No newline at end of file diff --git a/.idea/php.xml b/.idea/php.xml new file mode 100644 index 0000000..f324872 --- /dev/null +++ b/.idea/php.xml @@ -0,0 +1,19 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..35eb1dd --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/README.md b/README.md index 36abd58..fa9df4f 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,6 @@ Jo's NixOS configuration - ## Deployment Run this to apply your system configuration. diff --git a/flake.lock b/flake.lock index ce647a2..bd23675 100644 --- a/flake.lock +++ b/flake.lock @@ -1,103 +1,5 @@ { "nodes": { - "catppuccinifier": { - "inputs": { - "crane": "crane", - "flake-utils": "flake-utils_2", - "nixpkgs": [ - "nixpkgs" - ] - }, - "locked": { - "lastModified": 1696928114, - "narHash": "sha256-h445Aox0jck7MOCsKxXLKiE4QvptL/54eXUuhQZGF7o=", - "owner": "lighttigerXIV", - "repo": "catppuccinifier", - "rev": "ef9c180bb7bbf1486671a1c6df41adaab60a9b41", - "type": "github" - }, - "original": { - "owner": "lighttigerXIV", - "repo": "catppuccinifier", - "type": "github" - } - }, - "crane": { - "inputs": { - "flake-compat": "flake-compat", - "flake-utils": "flake-utils", - "nixpkgs": [ - "catppuccinifier", - "nixpkgs" - ], - "rust-overlay": "rust-overlay" - }, - "locked": { - "lastModified": 1687310026, - "narHash": "sha256-20RHFbrnC+hsG4Hyeg/58LvQAK7JWfFItTPFAFamu8E=", - "owner": "ipetkov", - "repo": "crane", - "rev": "116b32c30b5ff28e49f4fcbeeb1bbe3544593204", - "type": "github" - }, - "original": { - "owner": "ipetkov", - "repo": "crane", - "type": "github" - } - }, - "flake-compat": { - "flake": false, - "locked": { - "lastModified": 1673956053, - "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", - "owner": "edolstra", - "repo": "flake-compat", - "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", - "type": "github" - }, - "original": { - "owner": "edolstra", - "repo": "flake-compat", - "type": "github" - } - }, - "flake-utils": { - "inputs": { - "systems": "systems" - }, - "locked": { - "lastModified": 1685518550, - "narHash": "sha256-o2d0KcvaXzTrPRIo0kOLV0/QXHhDQ5DTi+OxcjO8xqY=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "a1720a10a6cfe8234c0e93907ffe81be440f4cef", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, - "flake-utils_2": { - "inputs": { - "systems": "systems_2" - }, - "locked": { - "lastModified": 1687171271, - "narHash": "sha256-BJlq+ozK2B1sJDQXS3tzJM5a+oVZmi1q0FlBK/Xqv7M=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "abfb11bd1aec8ced1c9bb9adfe68018230f4fb3c", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "home-manager": { "inputs": { "nixpkgs": [ @@ -105,11 +7,11 @@ ] }, "locked": { - "lastModified": 1698128422, - "narHash": "sha256-Qf39ATHrj6wfeC+K6uwD/FnI7RKrdEiN3uWaciUi0rM=", + "lastModified": 1713818326, + "narHash": "sha256-aw3xbVPJauLk/bbrlakIYxKpeuMWzA2feGrkIpIuXd8=", "owner": "nix-community", "repo": "home-manager", - "rev": "6045b68ee725167ed0487f0fb88123202ba61923", + "rev": "67de98ae6eed5ad6f91b1142356d71a87ba97f21", "type": "github" }, "original": { @@ -121,11 +23,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1697723726, - "narHash": "sha256-SaTWPkI8a5xSHX/rrKzUe+/uVNy6zCGMXgoeMb7T9rg=", + "lastModified": 1713714899, + "narHash": "sha256-+z/XjO3QJs5rLE5UOf015gdVauVRQd2vZtsFkaXBq2Y=", "owner": "nixos", "repo": "nixpkgs", - "rev": "7c9cc5a6e5d38010801741ac830a3f8fd667a7a0", + "rev": "6143fc5eeb9c4f00163267708e26191d1e918932", "type": "github" }, "original": { @@ -135,68 +37,34 @@ "type": "github" } }, - "root": { + "plasma-manager": { "inputs": { - "catppuccinifier": "catppuccinifier", - "home-manager": "home-manager", - "nixpkgs": "nixpkgs" - } - }, - "rust-overlay": { - "inputs": { - "flake-utils": [ - "catppuccinifier", - "crane", - "flake-utils" + "home-manager": [ + "home-manager" ], "nixpkgs": [ - "catppuccinifier", - "crane", "nixpkgs" ] }, "locked": { - "lastModified": 1685759304, - "narHash": "sha256-I3YBH6MS3G5kGzNuc1G0f9uYfTcNY9NYoRc3QsykLk4=", - "owner": "oxalica", - "repo": "rust-overlay", - "rev": "c535b4f3327910c96dcf21851bbdd074d0760290", + "lastModified": 1713805120, + "narHash": "sha256-WmqVyblqQ3g2Bmm+WONc1OnUuOuULQRIQya9wCLp5o8=", + "owner": "pjones", + "repo": "plasma-manager", + "rev": "ffeef9dc96a5a0e442479c94a6000f93b69aeaac", "type": "github" }, "original": { - "owner": "oxalica", - "repo": "rust-overlay", + "owner": "pjones", + "repo": "plasma-manager", "type": "github" } }, - "systems": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } - }, - "systems_2": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" + "root": { + "inputs": { + "home-manager": "home-manager", + "nixpkgs": "nixpkgs", + "plasma-manager": "plasma-manager" } } }, diff --git a/flake.nix b/flake.nix index b49b01d..a16ab3a 100644 --- a/flake.nix +++ b/flake.nix @@ -5,46 +5,51 @@ # Nixpkgs nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; - # Gnome testing branch (getting new major versions earlier) - # gnomeNixpkgs.url = "github:NixOS/nixpkgs/gnome"; - # Home manager - home-manager.url = "github:nix-community/home-manager/master"; - home-manager.inputs.nixpkgs.follows = "nixpkgs"; - - # Catppuccinifier - catppuccinifier = { - url = "github:lighttigerXIV/catppuccinifier"; + home-manager = { + url = "github:nix-community/home-manager/master"; inputs.nixpkgs.follows = "nixpkgs"; }; - # TODO: Add any other flake you might need - # hardware.url = "github:nixos/nixos-hardware"; - - # Shameless plug: looking for a way to nixify your themes and make - # everything match nicely? Try nix-colors! - # nix-colors.url = "github:misterio77/nix-colors"; + # Plasma manager + plasma-manager = { + url = "github:pjones/plasma-manager"; + inputs.nixpkgs.follows = "nixpkgs"; + inputs.home-manager.follows = "home-manager"; + }; }; - outputs = { - self, - nixpkgs, - home-manager, - catppuccinifier, - ... - } @ inputs: let + outputs = { self, nixpkgs, home-manager, plasma-manager, ... } @inputs: + let inherit (self) outputs; + + # Supported systems for this flake + systems = [ + "x86_64-linux" + ]; + + # Function that generates an attribute by calling a function you pass to it + # It takes each system as an argument + forAllSystems = nixpkgs.lib.genAttrs systems; in { + # My custom packages + packages = forAllSystems (system: import ./pkgs nixpkgs.legacyPackages.${system}); + + # My reusable modules for nixos + nixosModules = import ./modules/nixos; + + # My reusable modules for home-manager + homeManagerModules = import ./modules/home-manager; + # NixOS configuration entrypoint # Available through 'nixos-rebuild --flake .#your-hostname' nixosConfigurations = { - # FIXME replace with your hostname - nixos = nixpkgs.lib.nixosSystem { - specialArgs = {inherit inputs outputs catppuccinifier;}; - # > Our main nixos configuration file < + puzzlevision = nixpkgs.lib.nixosSystem { + specialArgs = {inherit inputs outputs;}; + modules = [ - ./nixos/configuration.nix - ./nixos/modules/desktop/kde.nix + ./hosts/puzzlevision/configuration.nix + ./modules/nixos/desktop/kde.nix ]; }; }; @@ -52,13 +57,13 @@ # Standalone home-manager configuration entrypoint # Available through 'home-manager --flake .#your-username@your-hostname' homeConfigurations = { - "jo@nixos" = home-manager.lib.homeManagerConfiguration { + "jo@puzzlevision" = home-manager.lib.homeManagerConfiguration { pkgs = nixpkgs.legacyPackages.x86_64-linux; # Home-manager requires 'pkgs' instance extraSpecialArgs = {inherit inputs outputs;}; # > Our main home-manager configuration file < modules = [ - ./home-manager/home.nix - ]; + ./home-manager/puzzlevision/home.nix + ]; }; }; }; diff --git a/home-manager/home.nix b/home-manager/home.nix deleted file mode 100644 index 26e49a9..0000000 --- a/home-manager/home.nix +++ /dev/null @@ -1,132 +0,0 @@ -{ - inputs, - lib, - config, - pkgs, - ... -}: { - # You can import other home-manager modules here - imports = [ - # If you want to use home-manager modules from other flakes (such as nix-colors): - # inputs.nix-colors.homeManagerModule - ]; - - nixpkgs = { - # You can add overlays here - overlays = [ - # If you want to use overlays exported from other flakes: - # neovim-nightly-overlay.overlays.default - - # Or define it inline, for example: - # (final: prev: { - # hi = final.hello.overrideAttrs (oldAttrs: { - # patches = [ ./change-hello-to-hi.patch ]; - # }); - # }) - ]; - # Configure your nixpkgs instance - config = { - # Disable if you don't want unfree packages - allowUnfree = true; - # Workaround for https://github.com/nix-community/home-manager/issues/2942 - allowUnfreePredicate = _: true; - }; - }; - - home = { - username = "jo"; - homeDirectory = "/home/jo"; - }; - - # home.packages = with pkgs.gnomeExtensions; [ - # user-themes - # dash-to-dock - # appindicator - # blur-my-shell - # rounded-window-corners - # ]; - - # dconf.settings = with lib.hm.gvariant; { - # "org/gnome/shell" = { - # disable-user-extensions = false; - # # enabled-extensions = map (extension: extension.extensionUuid) home.packages; - # disabled-extensions = [ ]; - # }; - - # "org/gnome/shell/extensions/user-theme" = { - # name = config.gtk.theme.name; - # }; - - # # "org/gnome/shell/extensions/dash-to-dock" = { - # # "appicon-margin" = 0; - # # "appicon-padding" = 6; - # # "tray-padding" = 4; - # # "click-action" = "TOGGLE-SHOWPREVIEW"; - # # "dot-position" = "TOP"; - # # "dot-style-focused" = "METRO"; - # # "dot-style-unfocused" = "DASHES"; - # # "group-apps" = true; - # # "isolate-workspaces" = true; - # # "middle-click-action" = "MINIMIZE"; - # # "shift-click-action" = "LAUNCH"; - # # "scroll-icon-action" = "NOTHING"; - # # "scroll-panel-action" = "NOTHING"; - # # "stockgs-panelbtn-click-only" = true; - # # }; - - # "org/gnome/desktop/interface" = { - # color-scheme = "prefer-dark"; - # clock-show-weekday = true; - # clock-show-date = true; - # clock-show-seconds = false; - # enable-hot-corners = false; - # }; - - # "org/gnome/desktop/input-sources" = { - # sources = [ (mkTuple [ "xkb" "de" ]) ]; - # }; - - # "org/gnome/shell" = { - # favorite-apps = [ - # "firefox.desktop" - # "org.gnome.Nautilus.desktop" - # ]; - # }; - # }; - - # gtk = { - # enable = true; - - # theme = { - # name = "Adw-gtk3"; - # package = pkgs.adw-gtk3; - # }; - - # cursorTheme = { - # name = "Catppuccin-Macchiato-Dark-Cursors"; - # package = pkgs.catppuccin-cursors.macchiatoRed; - # size = 32; - # }; - # }; - - # home.file.".config/gtk-4.0/gtk.css".source = "${orchis}/share/themes/Orchis-Green-Dark-Compact/gtk-4.0/gtk.css"; - # home.file.".config/gtk-4.0/gtk-dark.css".source = "${orchis}/share/themes/Orchis-Green-Dark-Compact/gtk-4.0/gtk-dark.css"; - # home.file.".config/gtk-4.0/assets" = { - # recursive = true; - # source = "${orchis}/share/themes/Orchis-Green-Dark-Compact/gtk-4.0/assets"; - # }; - - # Add stuff for your user as you see fit: - # programs.neovim.enable = true; - # home.packages = with pkgs; [ steam ]; - - # Enable home-manager and git - programs.home-manager.enable = true; - programs.git.enable = true; - - # Nicely reload system units when changing configs - systemd.user.startServices = "sd-switch"; - - # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion - home.stateVersion = "23.05"; -} diff --git a/home-manager/puzzlevision/home.nix b/home-manager/puzzlevision/home.nix new file mode 100644 index 0000000..bd0ef33 --- /dev/null +++ b/home-manager/puzzlevision/home.nix @@ -0,0 +1,55 @@ +{ + inputs, + lib, + config, + pkgs, + ... +}: { + # You can import other home-manager modules here + imports = [ + # If you want to use home-manager modules from other flakes (such as nix-colors): + # inputs.nix-colors.homeManagerModule + inputs.plasma-manager.homeManagerModules.plasma-manager + ]; + + nixpkgs = { + # You can add overlays here + overlays = []; + + # Configure your nixpkgs instance + config = { + allowUnfree = true; + + # Workaround for https://github.com/nix-community/home-manager/issues/2942 + allowUnfreePredicate = _: true; + }; + }; + + # Username and home directory + home = { + username = "jo"; + homeDirectory = "/home/jo"; + }; + + # Plasma configuration + programs.plasma = { + enable = true; + + workspace = { + clickItemTo = "select"; + iconTheme = "Tela-Blue-Dark"; + }; + }; + + # home.file.".config/gtk-4.0/gtk.css".source = "${orchis}/share/themes/Orchis-Green-Dark-Compact/gtk-4.0/gtk.css"; + + # Enable home-manager and git + programs.home-manager.enable = true; + programs.git.enable = true; + + # Nicely reload system units when changing configs + systemd.user.startServices = "sd-switch"; + + # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion + home.stateVersion = "23.05"; +} diff --git a/hosts/lenovo-pc/hardware.nix b/hosts/lenovo-pc/hardware.nix deleted file mode 100644 index e69de29..0000000 diff --git a/nixos/configuration.nix b/hosts/puzzlevision/configuration.nix similarity index 77% rename from nixos/configuration.nix rename to hosts/puzzlevision/configuration.nix index b836db1..6baa082 100644 --- a/nixos/configuration.nix +++ b/hosts/puzzlevision/configuration.nix @@ -53,14 +53,18 @@ options = "--delete-older-than 3d"; }; }; - + + # Install the latest kernel boot.kernelPackages = pkgs.linuxPackages_latest; + # Improve SSD performance + fileSystems."/".options = [ "noatime" "nodiratime" "discard" ]; + # Bootloader. boot.loader.systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = true; - networking.hostName = "nixos"; + networking.hostName = "puzzlevision"; # Enable networking networking.networkmanager.enable = true; @@ -104,45 +108,36 @@ hardware.bluetooth.enable = true; hardware.bluetooth.powerOnBoot = true; - networking.wg-quick = { - interfaces.homelab = { - privateKey = "kJ+2MOoYbtI6K00pJbVQshD7bXx/pjKw01wlMih9FFI="; - address = [ "10.8.0.2/24" ]; - dns = [ "1.1.1.1" ]; - - peers = [ - # For a client configuration, one peer entry for the server will suffice. - { - # Public key of the server (not a file path). - publicKey = "MTUi5FzlUQX1Vl2PLC72hnZnREn5kYRGqS6QSnaFeyQ="; - presharedKey = "Spzeg7KwMXuczdkpMygmzix5QBkgTOrR3lLlO7862yw="; - allowedIPs = [ "0.0.0.0/0" "::/0" ]; - endpoint = "jo-server.duckdns.org:51820"; - persistentKeepalive = 0; - } - ]; - }; - }; - # Enable docker virtualisation.docker.enable = true; # Enable touchpad support (enabled default in most desktopManager). services.xserver.libinput.enable = true; - # Define a user account. Don't forget to set a password with ‘passwd’. + # Configure keymap in X11 + services.xserver = { + xkb.layout = "de"; + xkb.variant = ""; + }; + + # Define a user account. users.users = { jo = { isNormalUser = true; description = "Jo"; - extraGroups = [ "networkmanager" "wheel" "docker" ]; + extraGroups = [ "networkmanager" "wheel" "docker" "tty" "dialout" ]; packages = with pkgs; [ - discord - ciscoPacketTracer8 - wireshark - joplin-desktop - teamspeak_client - virtualbox + spotify + qflipper + wineWowPackages.waylandFull + vesktop + avra + avrdude + jetbrains.phpstorm + teams-for-linux + enpass + thunderbird + kde-rounded-corners ]; }; @@ -152,10 +147,10 @@ initialPassword = "fortnite"; extraGroups = [ "networkmanager" ]; packages = with pkgs; [ - jetbrains.webstorm jetbrains.phpstorm teams-for-linux enpass + thunderbird ]; }; }; @@ -171,18 +166,12 @@ environment.systemPackages = with pkgs; [ nano firefox - thunderbird vlc libreoffice - wineWowPackages.waylandFull - xorg.xf86inputlibinput - gimp - ungoogled-chromium # For development - vscodium git - nodejs_20 + bun ]; # https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion diff --git a/nixos/hardware-configuration.nix b/hosts/puzzlevision/hardware-configuration.nix similarity index 63% rename from nixos/hardware-configuration.nix rename to hosts/puzzlevision/hardware-configuration.nix index aee149e..d27d0ae 100644 --- a/nixos/hardware-configuration.nix +++ b/hosts/puzzlevision/hardware-configuration.nix @@ -8,33 +8,42 @@ [ (modulesPath + "/installer/scan/not-detected.nix") ]; - boot.initrd.availableKernelModules = [ "xhci_pci" "vmd" "nvme" "usbhid" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ]; + boot.initrd.availableKernelModules = [ "xhci_pci" "vmd" "nvme" "rtsx_pci_sdmmc" ]; boot.initrd.kernelModules = [ ]; boot.kernelModules = [ "kvm-intel" ]; boot.extraModulePackages = [ ]; fileSystems."/" = - { device = "/dev/disk/by-uuid/9469c51e-bfcf-4d70-88e8-96e3cec4fbda"; - fsType = "ext4"; + { device = "/dev/disk/by-uuid/864b1287-89fd-4cc0-98a5-40a3caf804c6"; + fsType = "btrfs"; + options = [ "subvol=@" ]; }; + boot.initrd.luks.devices."luks-5fd4fc76-d5c5-46c3-b952-1a7a7ff3a1fc".device = "/dev/disk/by-uuid/5fd4fc76-d5c5-46c3-b952-1a7a7ff3a1fc"; + fileSystems."/boot" = - { device = "/dev/disk/by-uuid/7526-929F"; + { device = "/dev/disk/by-uuid/2429-4141"; fsType = "vfat"; + options = [ "fmask=0022" "dmask=0022" ]; }; - swapDevices = - [ { device = "/dev/disk/by-uuid/49ae48db-5d1e-421b-90c6-7e092847636c"; } - ]; + fileSystems."/var/lib/docker/btrfs" = + { device = "/@/var/lib/docker/btrfs"; + fsType = "none"; + options = [ "bind" ]; + }; + + swapDevices = [ ]; # Enables DHCP on each ethernet and wireless interface. In case of scripted networking # (the default) this is the recommended approach. When using systemd-networkd it's # still possible to use this option, but it's recommended to use it in conjunction # with explicit per-interface declarations with `networking.interfaces..useDHCP`. networking.useDHCP = lib.mkDefault true; + # networking.interfaces.br-9b746f4e7e2f.useDHCP = lib.mkDefault true; + # networking.interfaces.docker0.useDHCP = lib.mkDefault true; # networking.interfaces.wlo1.useDHCP = lib.mkDefault true; nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; - powerManagement.cpuFreqGovernor = lib.mkDefault "powersave"; hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; } diff --git a/modules/home-manager/default.nix b/modules/home-manager/default.nix new file mode 100644 index 0000000..95c7830 --- /dev/null +++ b/modules/home-manager/default.nix @@ -0,0 +1,6 @@ +# Collection of reusable home-manager modules (https://nixos.wiki/wiki/Module) +# These shouldn't include personal configurations, but much rather stuff that can be shared across multiple configurations +{ + # List your module files here + # my-module = import ./my-module.nix; +} diff --git a/modules/home-manager/themes/qt_catppuccin-macchiato.nix b/modules/home-manager/themes/qt_catppuccin-macchiato.nix new file mode 100644 index 0000000..8d1c8b6 --- /dev/null +++ b/modules/home-manager/themes/qt_catppuccin-macchiato.nix @@ -0,0 +1 @@ + diff --git a/modules/nixos/default.nix b/modules/nixos/default.nix new file mode 100644 index 0000000..6f7e667 --- /dev/null +++ b/modules/nixos/default.nix @@ -0,0 +1,6 @@ +# Collection of reusable nixos modules (https://nixos.wiki/wiki/Module) +# These shouldn't include personal configurations, but much rather stuff that can be shared across multiple configurations +{ + # List your module files here + # my-module = import ./my-module.nix; +} diff --git a/nixos/modules/desktop/gnome.nix b/modules/nixos/desktop/gnome.nix similarity index 73% rename from nixos/modules/desktop/gnome.nix rename to modules/nixos/desktop/gnome.nix index 72048d9..e2cb102 100644 --- a/nixos/modules/desktop/gnome.nix +++ b/modules/nixos/desktop/gnome.nix @@ -11,10 +11,4 @@ # Enable the GNOME Desktop Environment. services.xserver.displayManager.gdm.enable = true; services.xserver.desktopManager.gnome.enable = true; - - # Configure keymap in X11 - services.xserver = { - layout = "de"; - xkbVariant = ""; - }; -} \ No newline at end of file +} diff --git a/modules/nixos/desktop/kde.nix b/modules/nixos/desktop/kde.nix new file mode 100644 index 0000000..989618f --- /dev/null +++ b/modules/nixos/desktop/kde.nix @@ -0,0 +1,19 @@ +{ + inputs, + lib, + config, + pkgs, + ... +}: { + # Enable the x11 windowing system + services.xserver.enable = true; + + # Enable the SDDM display manager. + services.displayManager.sddm.enable = true; + + # Enable the KDE Plasma 6 desktop environment. + services.desktopManager.plasma6.enable = true; + + # Enable KDE-Connect + programs.kdeconnect.enable = true; +} diff --git a/nixos/modules/desktop/kde.nix b/nixos/modules/desktop/kde.nix deleted file mode 100644 index 7464f35..0000000 --- a/nixos/modules/desktop/kde.nix +++ /dev/null @@ -1,27 +0,0 @@ -{ - inputs, - lib, - config, - pkgs, - ... -}: { - # Enable the X11 windowing system. - services.xserver.enable = true; - - # Enable the GNOME Desktop Environment. - services.xserver.displayManager.sddm.enable = true; - services.xserver.desktopManager.plasma5.enable = true; - - # Configure keymap in X11 - services.xserver = { - layout = "de"; - xkbVariant = ""; - }; - - environment.systemPackages = with pkgs; [ - lightly-boehs - kde-rounded-corners - ]; - - programs.kdeconnect.enable = true; -} \ No newline at end of file diff --git a/pkgs/default.nix b/pkgs/default.nix new file mode 100644 index 0000000..3d9e23c --- /dev/null +++ b/pkgs/default.nix @@ -0,0 +1,5 @@ +# Custom packages, that can be defined similarly to ones from nixpkgs +# You can build them using 'nix build .#example' +pkgs: { + # example = pkgs.callPackage ./example { }; +}