diff --git a/configuration/main/configuration.nix b/configuration/main/configuration.nix index b373cb3..51e7384 100644 --- a/configuration/main/configuration.nix +++ b/configuration/main/configuration.nix @@ -10,5 +10,5 @@ ../modules/sddm.nix ]; - networking.firewall.allowedTCPPorts = [9123]; + networking.allowedTCPPorts = [9123]; } diff --git a/configuration/modules/desktop.nix b/configuration/modules/desktop.nix index df4e302..551df8d 100644 --- a/configuration/modules/desktop.nix +++ b/configuration/modules/desktop.nix @@ -1,8 +1,4 @@ { - pkgs, - inputs, - ... -}: { hardware.graphics = { enable = true; enable32Bit = true; @@ -11,16 +7,7 @@ xdg = { mime.enable = true; menus.enable = true; - portal = { - enable = true; - extraPortals = [pkgs.xdg-desktop-portal-cosmic]; - config.common.default = "cosmic"; - }; - }; - - programs.niri = { - enable = true; - package = inputs.niri-flake.packages.${pkgs.system}.niri-stable; + portal.enable = true; }; services.xserver = { diff --git a/configuration/modules/sddm.nix b/configuration/modules/sddm.nix index 5cfe298..9273ca8 100644 --- a/configuration/modules/sddm.nix +++ b/configuration/modules/sddm.nix @@ -14,7 +14,7 @@ in { qtvirtualkeyboard ]; enable = true; - wayland.enable = true; + wayland.enable = false; autoNumlock = true; enableHidpi = false; theme = "sddm-astronaut-theme"; diff --git a/configuration/modules/system.nix b/configuration/modules/system.nix index 279ed8a..d5a491a 100644 --- a/configuration/modules/system.nix +++ b/configuration/modules/system.nix @@ -1,6 +1,7 @@ { device-name, pkgs, + lib, ... }: { system.stateVersion = "25.11"; @@ -18,7 +19,7 @@ boot = { loader = { - systemd-boot.enable = true; + grub.enable = true; efi.canTouchEfiVariables = true; }; @@ -39,9 +40,6 @@ programs.noisetorch.enable = true; console.keyMap = "cz-lat2"; -services.xserver.xkb = { - layout = "cz"; -}; time.timeZone = "Europe/Prague"; i18n = { @@ -67,4 +65,9 @@ services.xserver.xkb = { openFirewall = true; }; }; + + environment.systemPackages = [ + (lib.hiPrio pkgs.uutils-coreutils.override {prefix = "";}) + (lib.hiPrio pkgs.uutils-findutils.override {prefix = "";}) + ]; } diff --git a/flake.lock b/flake.lock index fbabf49..f4728cb 100644 --- a/flake.lock +++ b/flake.lock @@ -256,64 +256,6 @@ "type": "github" } }, - "niri-flake": { - "inputs": { - "niri-stable": "niri-stable", - "niri-unstable": "niri-unstable", - "nixpkgs": [ - "nixpkgs" - ], - "nixpkgs-stable": "nixpkgs-stable", - "xwayland-satellite-stable": "xwayland-satellite-stable", - "xwayland-satellite-unstable": "xwayland-satellite-unstable" - }, - "locked": { - "lastModified": 1773501701, - "narHash": "sha256-+0LBAEm8F5h9Nm+hdS07aoS1W4oTtW6c8lltb66oOYQ=", - "owner": "sodiboo", - "repo": "niri-flake", - "rev": "39ac039250a4a32bf8691405cac04864fc66a70d", - "type": "github" - }, - "original": { - "owner": "sodiboo", - "repo": "niri-flake", - "type": "github" - } - }, - "niri-stable": { - "flake": false, - "locked": { - "lastModified": 1756556321, - "narHash": "sha256-RLD89dfjN0RVO86C/Mot0T7aduCygPGaYbog566F0Qo=", - "owner": "YaLTeR", - "repo": "niri", - "rev": "01be0e65f4eb91a9cd624ac0b76aaeab765c7294", - "type": "github" - }, - "original": { - "owner": "YaLTeR", - "ref": "v25.08", - "repo": "niri", - "type": "github" - } - }, - "niri-unstable": { - "flake": false, - "locked": { - "lastModified": 1773130184, - "narHash": "sha256-3bwx4WqCB06yfQIGB+OgIckOkEDyKxiTD5pOo4Xz2rI=", - "owner": "YaLTeR", - "repo": "niri", - "rev": "b07bde3ee82dd73115e6b949e4f3f63695da35ea", - "type": "github" - }, - "original": { - "owner": "YaLTeR", - "repo": "niri", - "type": "github" - } - }, "nixpkgs": { "locked": { "lastModified": 1773282481, @@ -330,22 +272,6 @@ "type": "github" } }, - "nixpkgs-stable": { - "locked": { - "lastModified": 1773375660, - "narHash": "sha256-SEzUWw2Rf5Ki3bcM26nSKgbeoqi2uYy8IHVBqOKjX3w=", - "owner": "NixOS", - "repo": "nixpkgs", - "rev": "3e20095fe3c6cbb1ddcef89b26969a69a1570776", - "type": "github" - }, - "original": { - "owner": "NixOS", - "ref": "nixos-25.11", - "repo": "nixpkgs", - "type": "github" - } - }, "nur": { "inputs": { "flake-parts": [ @@ -400,7 +326,6 @@ "inputs": { "floatc": "floatc", "home-manager": "home-manager", - "niri-flake": "niri-flake", "nixpkgs": "nixpkgs", "nvf": "nvf", "stylix": "stylix", @@ -573,39 +498,6 @@ "type": "github" } }, - "xwayland-satellite-stable": { - "flake": false, - "locked": { - "lastModified": 1755491097, - "narHash": "sha256-m+9tUfsmBeF2Gn4HWa6vSITZ4Gz1eA1F5Kh62B0N4oE=", - "owner": "Supreeeme", - "repo": "xwayland-satellite", - "rev": "388d291e82ffbc73be18169d39470f340707edaa", - "type": "github" - }, - "original": { - "owner": "Supreeeme", - "ref": "v0.7", - "repo": "xwayland-satellite", - "type": "github" - } - }, - "xwayland-satellite-unstable": { - "flake": false, - "locked": { - "lastModified": 1773499041, - "narHash": "sha256-XZ4/tVdLeAYDgKe4JD4C7yYUKydMxwt8c2j6APFWcIc=", - "owner": "Supreeeme", - "repo": "xwayland-satellite", - "rev": "309d8e2a29953f7465dc14c939e2afe4682c0aa9", - "type": "github" - }, - "original": { - "owner": "Supreeeme", - "repo": "xwayland-satellite", - "type": "github" - } - }, "zen-browser": { "inputs": { "nixpkgs": [ diff --git a/flake.nix b/flake.nix index a7bd823..d63aa33 100644 --- a/flake.nix +++ b/flake.nix @@ -51,6 +51,7 @@ inputs.home-manager.nixosModules.default { home-manager = { + enable = true; useUserPackages = true; useGlobalPkgs = true; diff --git a/home/modules/daily_apps.nix b/home/modules/daily_apps.nix index 9c270bc..a25eceb 100644 --- a/home/modules/daily_apps.nix +++ b/home/modules/daily_apps.nix @@ -1,8 +1,4 @@ -{ - pkgs, - inputs, - ... -}: { +{pkgs, ...}: { home.packages = with pkgs; [ # Browser inputs.zen-browser.packages.${pkgs.stdenv.hostPlatform.system}.default @@ -20,7 +16,6 @@ libreoffice trilium-desktop xournalpp - cosmic-files # Images pixieditor diff --git a/home/modules/default.nix b/home/modules/default.nix index e519352..97cea74 100644 --- a/home/modules/default.nix +++ b/home/modules/default.nix @@ -1,17 +1,54 @@ -{lib, ...}: { +{ + config, + lib, + ... +}: let + cfg = config.myModules; +in { options.myModules = { games.enable = lib.mkOption { type = lib.types.bool; default = false; description = "Enable games module."; }; + + dailyApps.enable = lib.mkOption { + type = lib.types.bool; + default = true; + description = "Enable daily applications."; + }; + + niri.enable = lib.mkOption { + type = lib.types.bool; + default = true; + description = "Enable niri wayland compositor config."; + }; + + nvf.enable = lib.mkOption { + type = lib.types.bool; + default = true; + description = "Enable nvf (neovim) configuration."; + }; + + shell.enable = lib.mkOption { + type = lib.types.bool; + default = true; + description = "Enable shell configuration."; + }; + + createProject.enable = lib.mkOption { + type = lib.types.bool; + default = true; + description = "Enable create-project tooling."; + }; }; + imports = [ - ./daily_apps.nix - ./niri.nix - ./nvf.nix - ./shell - ./create-project/create-project.nix - ./games + (lib.mkIf cfg.dailyApps.enable ./daily_apps.nix) + (lib.mkIf cfg.niri.enable ./niri.nix) + (lib.mkIf cfg.nvf.enable ./nvf.nix) + (lib.mkIf cfg.shell.enable ./shell.nix) + (lib.mkIf cfg.games.enable ./games/minecraft.nix) + (lib.mkIf cfg.createProject.enable ./create-project) ]; } diff --git a/home/modules/games/default.nix b/home/modules/games/default.nix deleted file mode 100644 index 6c98d49..0000000 --- a/home/modules/games/default.nix +++ /dev/null @@ -1,6 +0,0 @@ -{ - imports = [ - ./minecraft.nix - ./heroic.nix - ]; -} diff --git a/home/modules/games/heroic.nix b/home/modules/games/heroic.nix deleted file mode 100644 index 1850b17..0000000 --- a/home/modules/games/heroic.nix +++ /dev/null @@ -1,12 +0,0 @@ -{ - pkgs, - config, - lib, - ... -}: { - config = lib.mkIf config.myModules.games.enable { - home.packages = with pkgs; [ - heroic - ]; - }; -} diff --git a/home/modules/games/minecraft.nix b/home/modules/games/minecraft.nix index b97f1ed..0404c44 100644 --- a/home/modules/games/minecraft.nix +++ b/home/modules/games/minecraft.nix @@ -1,18 +1,12 @@ -{ - pkgs, - config, - lib, - ... -}: { - config = lib.mkIf config.myModules.games.enable { - home.packages = [ - (pkgs.prismlauncher.override { - jdks = [ - pkgs.temurin-bin-21 - pkgs.temurin-bin-8 - pkgs.temurin-bin-17 - ]; - }) - ]; - }; +{pkgs, ...}: { + home.packages = with pkgs; [ + heroic + (pkgs.prismlauncher.override { + jdks = [ + pkgs.temurin-bin-21 + pkgs.temurin-bin-8 + pkgs.temurin-bin-17 + ]; + }) + ]; } diff --git a/home/modules/niri.nix b/home/modules/niri.nix index b450afe..4a8305c 100644 --- a/home/modules/niri.nix +++ b/home/modules/niri.nix @@ -15,10 +15,6 @@ fuzzel.enable = true; swaylock.enable = true; waybar.enable = true; - foot.enable = true; - }; - - services = { mako.enable = true; swayidle.enable = true; polkit-gnome.enable = true; @@ -33,13 +29,6 @@ ]; input = { - keyboard.numlock = true; - warp-mouse-to-focus.enable = true; - - focus-follows-mouse = { - enable = true; - max-scroll-amount = "0%"; - }; keyboard = { xkb = { layout = "cz"; @@ -74,7 +63,7 @@ layout = { gaps = 8; - default-column-width = {proportion = 1.0;}; + default-column-width = {proportion = 1;}; preset-column-widths = [ {proportion = 0.33333;} @@ -102,6 +91,16 @@ } ]; + input = { + keyboard.numlock = true; + warp-mouse-to-focus.enable = true; + + focus-follows-mouse = { + enable = true; + max-scroll-amount = "0%"; + }; + }; + binds = { "Mod+Q".action.close-window = []; "Mod+Return".action.spawn = ["foot"]; diff --git a/home/modules/nvf.nix b/home/modules/nvf.nix index 1652760..f89d757 100644 --- a/home/modules/nvf.nix +++ b/home/modules/nvf.nix @@ -11,6 +11,11 @@ cursorline = true; color-modes = true; + indent = { + tab-width = 2; + unit = "\t"; + }; + lsp = { display-inlay-hints = true; display-messages = true; diff --git a/home/modules/shell/default.nix b/home/modules/shell/default.nix deleted file mode 100644 index 96696e7..0000000 --- a/home/modules/shell/default.nix +++ /dev/null @@ -1,5 +0,0 @@ -{ - imports = [ - ./shell.nix - ]; -} diff --git a/home/modules/shell/shell.nix b/home/modules/shell/shell.nix index dc9367c..294f13f 100644 --- a/home/modules/shell/shell.nix +++ b/home/modules/shell/shell.nix @@ -1,7 +1,6 @@ { pkgs, device-name, - inputs, ... }: { home.packages = with pkgs; [ @@ -34,7 +33,7 @@ nushell = { enable = true; - extraConfig = builtins.readFile ./config.nu; + extraConfig = builtins.readFile "config.nu"; settings = { show_banner = false;