commit c7a17f77725174f6da03b4bfb2a3fba06a6709d3 Author: Lilly Date: Mon Jan 5 04:04:36 2026 +0100 First Commit diff --git a/configuration.nix b/configuration.nix new file mode 100644 index 0000000..f7322e0 --- /dev/null +++ b/configuration.nix @@ -0,0 +1,75 @@ +# Edit this configuration file to define what should be installed on +# your system. Help is available in the configuration.nix(5) man page +# and in the NixOS manual (accessible by running ‘nixos-help’). + +{ inputs, host, ... }: + +{ + + imports = + [ + ./hosts/${host} + ./options.nix + ./system + ./modules + ]; + + # Set your time zone. + time.timeZone = "Europe/Berlin"; + + # Select internationalisation properties. + i18n.defaultLocale = "en_US.UTF-8"; + + i18n.extraLocaleSettings = { + LC_ADDRESS = "en_US.UTF-8"; + LC_IDENTIFICATION = "en_US.UTF-8"; + LC_MEASUREMENT = "en_US.UTF-8"; + LC_MONETARY = "en_US.UTF-8"; + LC_NAME = "en_US.UTF-8"; + LC_NUMERIC = "en_US.UTF-8"; + LC_PAPER = "en_US.UTF-8"; + LC_TELEPHONE = "en_US.UTF-8"; + LC_TIME = "en_US.UTF-8"; + }; + + # Configure keymap in X11 + services.xserver.xkb = { + layout = "us"; + variant = "euro"; + }; + + + # Allow unfree packages + nixpkgs.config.allowUnfree = true; + nixpkgs.overlays = [ + inputs.nix-cachyos-kernel.overlays.pinned + ]; + + # Some programs need SUID wrappers, can be configured further or are + # started in user sessions. + # programs.mtr.enable = true; + programs.gnupg.agent = { + enable = true; + enableSSHSupport = true; + }; + + # List services that you want to enable: + + # Enable the OpenSSH daemon. + services.openssh.enable = true; + + # Open ports in the firewall. + # networking.firewall.allowedTCPPorts = [ ... ]; + # networking.firewall.allowedUDPPorts = [ ... ]; + # Or disable the firewall altogether. + # networking.firewall.enable = false; + + # This value determines the NixOS release from which the default + # settings for stateful data, like file locations and database versions + # on your system were taken. It‘s perfectly fine and recommended to leave + # this value at the release version of the first install of this system. + # Before changing this value read the documentation for this option + # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). + system.stateVersion = "25.11"; # Did you read the comment? + +} diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..3ad63a4 --- /dev/null +++ b/flake.lock @@ -0,0 +1,1009 @@ +{ + "nodes": { + "aagl": { + "inputs": { + "flake-compat": "flake-compat", + "nixpkgs": [ + "nixpkgs" + ], + "rust-overlay": "rust-overlay" + }, + "locked": { + "lastModified": 1766424307, + "narHash": "sha256-DzRLGukYRf+cnGyF9ukg/1n4mtgG3hKBrzE1fHCNZ2w=", + "owner": "ezKEa", + "repo": "aagl-gtk-on-nix", + "rev": "1dc0259e0dd6c3eba5ff96b7f597b6cf5627c62c", + "type": "github" + }, + "original": { + "owner": "ezKEa", + "ref": "release-25.11", + "repo": "aagl-gtk-on-nix", + "type": "github" + } + }, + "aquamarine": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1765900596, + "narHash": "sha256-+hn8v9jkkLP9m+o0Nm5SiEq10W0iWDSotH2XfjU45fA=", + "owner": "hyprwm", + "repo": "aquamarine", + "rev": "d83c97f8f5c0aae553c1489c7d9eff3eadcadace", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "aquamarine", + "type": "github" + } + }, + "artemisrgb": { + "inputs": { + "nixpkgs": "nixpkgs_2" + }, + "locked": { + "path": "./services/artemis-rgb", + "type": "path" + }, + "original": { + "path": "./services/artemis-rgb", + "type": "path" + }, + "parent": [] + }, + "cachyos-kernel": { + "flake": false, + "locked": { + "lastModified": 1767027640, + "narHash": "sha256-3WiDgNSE+77mVEAhlYFW3sRvS5fRTcIQAw9g76uUXIg=", + "owner": "CachyOS", + "repo": "linux-cachyos", + "rev": "f29baa3a13d3756dbd8836ed646622af803f79a3", + "type": "github" + }, + "original": { + "owner": "CachyOS", + "repo": "linux-cachyos", + "type": "github" + } + }, + "cachyos-kernel-patches": { + "flake": false, + "locked": { + "lastModified": 1767026526, + "narHash": "sha256-l3FEhseehO2On1FPlDbtFUc94LEc1ZvmUxQpLID119g=", + "owner": "CachyOS", + "repo": "kernel-patches", + "rev": "dd86f5f1e1c87b8bc3d8cabf2c655fe2b2c5e144", + "type": "github" + }, + "original": { + "owner": "CachyOS", + "repo": "kernel-patches", + "type": "github" + } + }, + "catppuccin": { + "inputs": { + "nixpkgs": "nixpkgs_3" + }, + "locked": { + "lastModified": 1765990358, + "narHash": "sha256-l8x0gU8mnYaGMl+gWrsSHKBJlZWD8KXJfHTkRlFiPI0=", + "owner": "catppuccin", + "repo": "nix", + "rev": "de1b60ca45a578f59f7d84c8d338b346017b2161", + "type": "github" + }, + "original": { + "owner": "catppuccin", + "repo": "nix", + "type": "github" + } + }, + "dgop": { + "inputs": { + "nixpkgs": [ + "dms", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1762835999, + "narHash": "sha256-UykYGrGFOFTmDpKTLNxj1wvd1gbDG4TkqLNSbV0TYwk=", + "owner": "AvengeMedia", + "repo": "dgop", + "rev": "799301991cd5dcea9b64245f9d500dcc76615653", + "type": "github" + }, + "original": { + "owner": "AvengeMedia", + "repo": "dgop", + "type": "github" + } + }, + "dms": { + "inputs": { + "dgop": "dgop", + "nixpkgs": [ + "nixpkgs" + ], + "quickshell": "quickshell" + }, + "locked": { + "lastModified": 1765552734, + "narHash": "sha256-rWjWYu5rs3ZOJ4YJpvIscBZSYu74thJHc0VYyYKJTUc=", + "owner": "AvengeMedia", + "repo": "DankMaterialShell", + "rev": "7fb358bada0d3a229ec5ee6aaad0f9b64f367331", + "type": "github" + }, + "original": { + "owner": "AvengeMedia", + "ref": "stable", + "repo": "DankMaterialShell", + "type": "github" + } + }, + "firefox-addons": { + "inputs": { + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "dir": "pkgs/firefox-addons", + "lastModified": 1767240209, + "narHash": "sha256-ME1S/jUwNOTP7p/UKbRDJhdxWe4f9OJ54wUDADrHhXQ=", + "owner": "rycee", + "repo": "nur-expressions", + "rev": "e46982ad70f4a16bb2a29a34105d1e75f7f0d45d", + "type": "gitlab" + }, + "original": { + "dir": "pkgs/firefox-addons", + "owner": "rycee", + "repo": "nur-expressions", + "type": "gitlab" + } + }, + "flake-compat": { + "flake": false, + "locked": { + "lastModified": 1761588595, + "narHash": "sha256-XKUZz9zewJNUj46b4AJdiRZJAvSZ0Dqj2BNfXvFlJC4=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "f387cd2afec9419c8ee37694406ca490c3f34ee5", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-compat_2": { + "flake": false, + "locked": { + "lastModified": 1761588595, + "narHash": "sha256-XKUZz9zewJNUj46b4AJdiRZJAvSZ0Dqj2BNfXvFlJC4=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "f387cd2afec9419c8ee37694406ca490c3f34ee5", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-compat_3": { + "flake": false, + "locked": { + "lastModified": 1767039857, + "narHash": "sha256-vNpUSpF5Nuw8xvDLj2KCwwksIbjua2LZCqhV1LNRDns=", + "owner": "NixOS", + "repo": "flake-compat", + "rev": "5edf11c44bc78a0d334f6334cdaf7d60d732daab", + "type": "github" + }, + "original": { + "owner": "NixOS", + "repo": "flake-compat", + "type": "github" + } + }, + "flake-parts": { + "inputs": { + "nixpkgs-lib": "nixpkgs-lib" + }, + "locked": { + "lastModified": 1765835352, + "narHash": "sha256-XswHlK/Qtjasvhd1nOa1e8MgZ8GS//jBoTqWtrS1Giw=", + "owner": "hercules-ci", + "repo": "flake-parts", + "rev": "a34fae9c08a15ad73f295041fec82323541400a9", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "flake-parts", + "type": "github" + } + }, + "gitignore": { + "inputs": { + "nixpkgs": [ + "hyprland", + "pre-commit-hooks", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1709087332, + "narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=", + "owner": "hercules-ci", + "repo": "gitignore.nix", + "rev": "637db329424fd7e46cf4185293b9cc8c88c95394", + "type": "github" + }, + "original": { + "owner": "hercules-ci", + "repo": "gitignore.nix", + "type": "github" + } + }, + "home-manager": { + "inputs": { + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1767024057, + "narHash": "sha256-B1aycRjMRvb6QOGbnqDhiDzZwMebj5jxZ5qyJzaKvpI=", + "owner": "nix-community", + "repo": "home-manager", + "rev": "34578a2fdfce4257ce5f5baf6e7efbd4e4e252b1", + "type": "github" + }, + "original": { + "owner": "nix-community", + "ref": "release-25.11", + "repo": "home-manager", + "type": "github" + } + }, + "hyprcursor": { + "inputs": { + "hyprlang": [ + "hyprland", + "hyprlang" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1753964049, + "narHash": "sha256-lIqabfBY7z/OANxHoPeIrDJrFyYy9jAM4GQLzZ2feCM=", + "owner": "hyprwm", + "repo": "hyprcursor", + "rev": "44e91d467bdad8dcf8bbd2ac7cf49972540980a5", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprcursor", + "type": "github" + } + }, + "hyprgraphics": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1763733840, + "narHash": "sha256-JnET78yl5RvpGuDQy3rCycOCkiKoLr5DN1fPhRNNMco=", + "owner": "hyprwm", + "repo": "hyprgraphics", + "rev": "8f1bec691b2d198c60cccabca7a94add2df4ed1a", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprgraphics", + "type": "github" + } + }, + "hyprland": { + "inputs": { + "aquamarine": "aquamarine", + "hyprcursor": "hyprcursor", + "hyprgraphics": "hyprgraphics", + "hyprland-guiutils": "hyprland-guiutils", + "hyprland-protocols": "hyprland-protocols", + "hyprlang": "hyprlang", + "hyprutils": "hyprutils", + "hyprwayland-scanner": "hyprwayland-scanner", + "hyprwire": "hyprwire", + "nixpkgs": "nixpkgs_4", + "pre-commit-hooks": "pre-commit-hooks", + "systems": "systems", + "xdph": "xdph" + }, + "locked": { + "lastModified": 1767201430, + "narHash": "sha256-2FF66EaIbsc7CL1jKHbRFslSePDq40fzlTTbUlm5v3k=", + "owner": "hyprwm", + "repo": "Hyprland", + "rev": "48a024e0322bbd7c4c88126498ec478444ec4cb2", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "Hyprland", + "type": "github" + } + }, + "hyprland-guiutils": { + "inputs": { + "aquamarine": [ + "hyprland", + "aquamarine" + ], + "hyprgraphics": [ + "hyprland", + "hyprgraphics" + ], + "hyprlang": [ + "hyprland", + "hyprlang" + ], + "hyprtoolkit": "hyprtoolkit", + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1765643131, + "narHash": "sha256-CCGohW5EBIRy4B7vTyBMqPgsNcaNenVad/wszfddET0=", + "owner": "hyprwm", + "repo": "hyprland-guiutils", + "rev": "e50ae912813bdfa8372d62daf454f48d6df02297", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprland-guiutils", + "type": "github" + } + }, + "hyprland-protocols": { + "inputs": { + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1765214753, + "narHash": "sha256-P9zdGXOzToJJgu5sVjv7oeOGPIIwrd9hAUAP3PsmBBs=", + "owner": "hyprwm", + "repo": "hyprland-protocols", + "rev": "3f3860b869014c00e8b9e0528c7b4ddc335c21ab", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprland-protocols", + "type": "github" + } + }, + "hyprlang": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1764612430, + "narHash": "sha256-54ltTSbI6W+qYGMchAgCR6QnC1kOdKXN6X6pJhOWxFg=", + "owner": "hyprwm", + "repo": "hyprlang", + "rev": "0d00dc118981531aa731150b6ea551ef037acddd", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprlang", + "type": "github" + } + }, + "hyprtoolkit": { + "inputs": { + "aquamarine": [ + "hyprland", + "hyprland-guiutils", + "aquamarine" + ], + "hyprgraphics": [ + "hyprland", + "hyprland-guiutils", + "hyprgraphics" + ], + "hyprlang": [ + "hyprland", + "hyprland-guiutils", + "hyprlang" + ], + "hyprutils": [ + "hyprland", + "hyprland-guiutils", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprland-guiutils", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "hyprland-guiutils", + "nixpkgs" + ], + "systems": [ + "hyprland", + "hyprland-guiutils", + "systems" + ] + }, + "locked": { + "lastModified": 1764592794, + "narHash": "sha256-7CcO+wbTJ1L1NBQHierHzheQGPWwkIQug/w+fhTAVuU=", + "owner": "hyprwm", + "repo": "hyprtoolkit", + "rev": "5cfe0743f0e608e1462972303778d8a0859ee63e", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprtoolkit", + "type": "github" + } + }, + "hyprutils": { + "inputs": { + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1766160771, + "narHash": "sha256-roINUGikWRqqgKrD4iotKbGj3ZKJl3hjMz5l/SyKrHw=", + "owner": "hyprwm", + "repo": "hyprutils", + "rev": "5ac060bfcf2f12b3a6381156ebbc13826a05b09f", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprutils", + "type": "github" + } + }, + "hyprwayland-scanner": { + "inputs": { + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1763640274, + "narHash": "sha256-Uan1Nl9i4TF/kyFoHnTq1bd/rsWh4GAK/9/jDqLbY5A=", + "owner": "hyprwm", + "repo": "hyprwayland-scanner", + "rev": "f6cf414ca0e16a4d30198fd670ec86df3c89f671", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprwayland-scanner", + "type": "github" + } + }, + "hyprwire": { + "inputs": { + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1766253200, + "narHash": "sha256-26qPwrd3od+xoYVywSB7hC2cz9ivN46VPLlrsXyGxvE=", + "owner": "hyprwm", + "repo": "hyprwire", + "rev": "1079777525b30a947c8d657fac158e00ae85de9d", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "hyprwire", + "type": "github" + } + }, + "nix-cachyos-kernel": { + "inputs": { + "cachyos-kernel": "cachyos-kernel", + "cachyos-kernel-patches": "cachyos-kernel-patches", + "flake-compat": "flake-compat_3", + "flake-parts": "flake-parts", + "nixpkgs": "nixpkgs_5" + }, + "locked": { + "lastModified": 1767116963, + "narHash": "sha256-QXJGrhvxCFRjiBFoet2tPZeYVDMQP3uJ7U2rVNqksnk=", + "owner": "xddxdd", + "repo": "nix-cachyos-kernel", + "rev": "025497db5d60c1c4c37ba3094a498998543e29a3", + "type": "github" + }, + "original": { + "owner": "xddxdd", + "ref": "release", + "repo": "nix-cachyos-kernel", + "type": "github" + } + }, + "nix-flatpak": { + "locked": { + "lastModified": 1739444422, + "narHash": "sha256-iAVVHi7X3kWORftY+LVbRiStRnQEob2TULWyjMS6dWg=", + "owner": "gmodena", + "repo": "nix-flatpak", + "rev": "5e54c3ca05a7c7d968ae1ddeabe01d2a9bc1e177", + "type": "github" + }, + "original": { + "owner": "gmodena", + "ref": "latest", + "repo": "nix-flatpak", + "type": "github" + } + }, + "nixpkgs": { + "locked": { + "lastModified": 1744536153, + "narHash": "sha256-awS2zRgF4uTwrOKwwiJcByDzDOdo3Q1rPZbiHQg/N38=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "18dd725c29603f582cf1900e0d25f9f1063dbf11", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixpkgs-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs-lib": { + "locked": { + "lastModified": 1765674936, + "narHash": "sha256-k00uTP4JNfmejrCLJOwdObYC9jHRrr/5M/a/8L2EIdo=", + "owner": "nix-community", + "repo": "nixpkgs.lib", + "rev": "2075416fcb47225d9b68ac469a5c4801a9c4dd85", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "nixpkgs.lib", + "type": "github" + } + }, + "nixpkgs_2": { + "locked": { + "lastModified": 1767047869, + "narHash": "sha256-tzYsEzXEVa7op1LTnrLSiPGrcCY6948iD0EcNLWcmzo=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "89dbf01df72eb5ebe3b24a86334b12c27d68016a", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-25.11", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_3": { + "locked": { + "lastModified": 1763966396, + "narHash": "sha256-6eeL1YPcY1MV3DDStIDIdy/zZCDKgHdkCmsrLJFiZf0=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "5ae3b07d8d6527c42f17c876e404993199144b6a", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_4": { + "locked": { + "lastModified": 1766070988, + "narHash": "sha256-G/WVghka6c4bAzMhTwT2vjLccg/awmHkdKSd2JrycLc=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "c6245e83d836d0433170a16eb185cefe0572f8b8", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_5": { + "locked": { + "lastModified": 1767031366, + "narHash": "sha256-CGXYat7ldAoD3GBZ+ETInHmQUCpHVzYmaQCQ4oKM9Q4=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "d23fedd87fcd067b1d160323fae0d0e4f995527d", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable-small", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_6": { + "locked": { + "lastModified": 1767081933, + "narHash": "sha256-aFw7KQeFeAZ8Nz0uzHtpR3nykKxcDs7UxS5+Vknq0O4=", + "owner": "nixos", + "repo": "nixpkgs", + "rev": "9a8f741fecfa888c1f79d081bf6af0680d9c1516", + "type": "github" + }, + "original": { + "owner": "nixos", + "ref": "release-25.11", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_7": { + "locked": { + "lastModified": 1767047869, + "narHash": "sha256-tzYsEzXEVa7op1LTnrLSiPGrcCY6948iD0EcNLWcmzo=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "89dbf01df72eb5ebe3b24a86334b12c27d68016a", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-25.11", + "repo": "nixpkgs", + "type": "github" + } + }, + "nixpkgs_8": { + "locked": { + "lastModified": 1766651565, + "narHash": "sha256-QEhk0eXgyIqTpJ/ehZKg9IKS7EtlWxF3N7DXy42zPfU=", + "owner": "NixOS", + "repo": "nixpkgs", + "rev": "3e2499d5539c16d0d173ba53552a4ff8547f4539", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "nixos-unstable", + "repo": "nixpkgs", + "type": "github" + } + }, + "openlinkhub": { + "inputs": { + "nixpkgs": "nixpkgs_7" + }, + "locked": { + "path": "./services/openlinkhub", + "type": "path" + }, + "original": { + "path": "./services/openlinkhub", + "type": "path" + }, + "parent": [] + }, + "pre-commit-hooks": { + "inputs": { + "flake-compat": "flake-compat_2", + "gitignore": "gitignore", + "nixpkgs": [ + "hyprland", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1765911976, + "narHash": "sha256-t3T/xm8zstHRLx+pIHxVpQTiySbKqcQbK+r+01XVKc0=", + "owner": "cachix", + "repo": "git-hooks.nix", + "rev": "b68b780b69702a090c8bb1b973bab13756cc7a27", + "type": "github" + }, + "original": { + "owner": "cachix", + "repo": "git-hooks.nix", + "type": "github" + } + }, + "quickshell": { + "inputs": { + "nixpkgs": [ + "dms", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1764663772, + "narHash": "sha256-sHqLmm0wAt3PC4vczJeBozI1/f4rv9yp3IjkClHDXDs=", + "ref": "refs/heads/master", + "rev": "26531fc46ef17e9365b03770edd3fb9206fcb460", + "revCount": 713, + "type": "git", + "url": "https://git.outfoxxed.me/quickshell/quickshell" + }, + "original": { + "rev": "26531fc46ef17e9365b03770edd3fb9206fcb460", + "type": "git", + "url": "https://git.outfoxxed.me/quickshell/quickshell" + } + }, + "root": { + "inputs": { + "aagl": "aagl", + "artemisrgb": "artemisrgb", + "catppuccin": "catppuccin", + "dms": "dms", + "firefox-addons": "firefox-addons", + "home-manager": "home-manager", + "hyprland": "hyprland", + "nix-cachyos-kernel": "nix-cachyos-kernel", + "nix-flatpak": "nix-flatpak", + "nixpkgs": "nixpkgs_6", + "openlinkhub": "openlinkhub", + "spicetify-nix": "spicetify-nix", + "zen-browser": "zen-browser" + } + }, + "rust-overlay": { + "inputs": { + "nixpkgs": "nixpkgs" + }, + "locked": { + "lastModified": 1764124769, + "narHash": "sha256-vcoOEy3i8AGJi3Y2C48hrf6CuL2h8W1gLe1gNt72Kxg=", + "owner": "oxalica", + "repo": "rust-overlay", + "rev": "5da8c00313b4434f00aed6b4c94cd3b207bafdc5", + "type": "github" + }, + "original": { + "owner": "oxalica", + "repo": "rust-overlay", + "type": "github" + } + }, + "spicetify-nix": { + "inputs": { + "nixpkgs": "nixpkgs_8", + "systems": "systems_2" + }, + "locked": { + "lastModified": 1767195736, + "narHash": "sha256-0xvPSbhIGeJzsJXNTkgJ3PjwdVItKm85wzYKA9NmSzI=", + "owner": "Gerg-L", + "repo": "spicetify-nix", + "rev": "465adc0ab6ff0c4b9b1db1c6e7fd7eeb553b3261", + "type": "github" + }, + "original": { + "owner": "Gerg-L", + "repo": "spicetify-nix", + "type": "github" + } + }, + "systems": { + "locked": { + "lastModified": 1689347949, + "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", + "owner": "nix-systems", + "repo": "default-linux", + "rev": "31732fcf5e8fea42e59c2488ad31a0e651500f68", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default-linux", + "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" + } + }, + "xdph": { + "inputs": { + "hyprland-protocols": [ + "hyprland", + "hyprland-protocols" + ], + "hyprlang": [ + "hyprland", + "hyprlang" + ], + "hyprutils": [ + "hyprland", + "hyprutils" + ], + "hyprwayland-scanner": [ + "hyprland", + "hyprwayland-scanner" + ], + "nixpkgs": [ + "hyprland", + "nixpkgs" + ], + "systems": [ + "hyprland", + "systems" + ] + }, + "locked": { + "lastModified": 1761431178, + "narHash": "sha256-xzjC1CV3+wpUQKNF+GnadnkeGUCJX+vgaWIZsnz9tzI=", + "owner": "hyprwm", + "repo": "xdg-desktop-portal-hyprland", + "rev": "4b8801228ff958d028f588f0c2b911dbf32297f9", + "type": "github" + }, + "original": { + "owner": "hyprwm", + "repo": "xdg-desktop-portal-hyprland", + "type": "github" + } + }, + "zen-browser": { + "inputs": { + "home-manager": [ + "home-manager" + ], + "nixpkgs": [ + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1767239595, + "narHash": "sha256-QUfbe5AJP2f190ugNNb4y12ZzOWTnCi66yuM3iYRBzE=", + "owner": "0xc000022070", + "repo": "zen-browser-flake", + "rev": "5776ae08801a16562b5626a64dedc57032f9a430", + "type": "github" + }, + "original": { + "owner": "0xc000022070", + "repo": "zen-browser-flake", + "type": "github" + } + } + }, + "root": "root", + "version": 7 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..fca4c17 --- /dev/null +++ b/flake.nix @@ -0,0 +1,95 @@ +{ + description = "LillyOS"; + + inputs = { + nixpkgs.url = "github:nixos/nixpkgs/release-25.11"; + home-manager = { + url = "github:nix-community/home-manager/release-25.11"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + zen-browser = { + url = "github:0xc000022070/zen-browser-flake"; + inputs.nixpkgs.follows = "nixpkgs"; + inputs.home-manager.follows = "home-manager"; + }; + dms = { + url = "github:AvengeMedia/DankMaterialShell/stable"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + hyprland.url = "github:hyprwm/Hyprland"; + nix-cachyos-kernel.url = "github:xddxdd/nix-cachyos-kernel/release"; + nix-flatpak.url = "github:gmodena/nix-flatpak?ref=latest"; + catppuccin.url = "github:catppuccin/nix"; + firefox-addons = { + url = "gitlab:rycee/nur-expressions?dir=pkgs/firefox-addons"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + openlinkhub.url = "path:./services/openlinkhub"; + artemisrgb.url = "path:./services/artemis-rgb"; + spicetify-nix.url = "github:Gerg-L/spicetify-nix"; + aagl = { + url = "github:ezKEa/aagl-gtk-on-nix/release-25.11"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + }; + + outputs = { + self, + nixpkgs, + home-manager, + hyprland, + nix-flatpak, + catppuccin, + ... + } @inputs: + let + host = "lillypc"; + username = "lilly"; + prettyUsername = "Lilly"; + email = "lilly@hibana.me"; + system = "x86_64-linux"; + in + { + nixosConfigurations.lillypc = nixpkgs.lib.nixosSystem { + inherit system; + specialArgs = { + inherit inputs; + inherit host; + inherit username; + inherit prettyUsername; + }; + modules = [ + ./configuration.nix + nix-flatpak.nixosModules.nix-flatpak + catppuccin.nixosModules.catppuccin + home-manager.nixosModules.home-manager + { + home-manager = { + useUserPackages = true; + useGlobalPkgs = false; + backupFileExtension = "backup"; + extraSpecialArgs = { + inherit inputs; + inherit host; + inherit username; + inherit prettyUsername; + inherit email; + }; + users.${username} = { + imports = [ + ./home + catppuccin.homeModules.catppuccin + ]; + home = { + username = "${username}"; + homeDirectory = "/home/${username}"; + stateVersion = "25.11"; + }; + }; + }; + } + ]; + }; + }; +} + diff --git a/home/catppuccin.nix b/home/catppuccin.nix new file mode 100644 index 0000000..aebff7a --- /dev/null +++ b/home/catppuccin.nix @@ -0,0 +1,31 @@ +{ + pkgs, + ... +}: +let + variant = "mocha"; + accent = "mauve"; +in +{ + catppuccin = { + enable = true; + accent = "${accent}"; + flavor = "${variant}"; + vscode.profiles.default.enable = false; + cursors.enable = true; + }; + + gtk = { + enable = true; + theme = { + name = "Catppuccin-GTK-Dark"; + package = pkgs.magnetic-catppuccin-gtk; + }; + }; + + qt = { + enable = true; + platformTheme.name = "ct"; + style.name = "kvantum"; + }; +} \ No newline at end of file diff --git a/home/default.nix b/home/default.nix new file mode 100644 index 0000000..18ed1e6 --- /dev/null +++ b/home/default.nix @@ -0,0 +1,20 @@ +{ lib, ... }: +let + b = builtins; + + module_files = + b.readDir ./. |> + lib.filterAttrs (name: type: + ( (lib.strings.hasSuffix ".nix" name + && name != "default.nix" + && type == "regular" ) + || ( type == "directory" + && b.pathExists ./${name}/default.nix)) + ) |> + b.attrNames |> + b.map (f: ./${f}); +in +{ + imports = module_files; + nixpkgs.config.allowUnfree = true; +} \ No newline at end of file diff --git a/home/easyeffects.nix b/home/easyeffects.nix new file mode 100644 index 0000000..86c4100 --- /dev/null +++ b/home/easyeffects.nix @@ -0,0 +1,5 @@ +{ + services.easyeffects = { + enable = true; + }; +} \ No newline at end of file diff --git a/home/gaming/default.nix b/home/gaming/default.nix new file mode 100644 index 0000000..18bdf06 --- /dev/null +++ b/home/gaming/default.nix @@ -0,0 +1,5 @@ +_: { + imports = [ + ./mangohud.nix + ]; +} diff --git a/home/gaming/mangohud.nix b/home/gaming/mangohud.nix new file mode 100644 index 0000000..7b26ded --- /dev/null +++ b/home/gaming/mangohud.nix @@ -0,0 +1,5 @@ +{ + programs.mangohud = { + enable = true; + }; +} diff --git a/home/gnome-keyring.nix b/home/gnome-keyring.nix new file mode 100644 index 0000000..44c0513 --- /dev/null +++ b/home/gnome-keyring.nix @@ -0,0 +1,5 @@ +{ pkgs, ...}: +{ + services.gnome-keyring.enable = true; + home.packages = [ pkgs.gcr ]; # Provides org.gnome.keyring.SystemPrompter +} diff --git a/home/hyprland/animations.nix b/home/hyprland/animations.nix new file mode 100644 index 0000000..f378ecf --- /dev/null +++ b/home/hyprland/animations.nix @@ -0,0 +1,41 @@ +{ + wayland.windowManager.hyprland = { + settings = { + animations = { + enabled = true; + bezier = [ + # Curves + "expressiveFastSpatial, 0.42, 1.67, 0.21, 0.90" + "expressiveSlowSpatial, 0.39, 1.29, 0.35, 0.98" + "expressiveDefaultSpatial, 0.38, 1.21, 0.22, 1.00" + "emphasizedDecel, 0.05, 0.7, 0.1, 1" + "emphasizedAccel, 0.3, 0, 0.8, 0.15" + "standardDecel, 0, 0, 0, 1" + "menu_decel, 0.1, 1, 0, 1" + "menu_accel, 0.52, 0.03, 0.72, 0.08" + ]; + animation = [ + # Configs + # windows + "windowsIn, 1, 2, emphasizedDecel, popin 80%" + "windowsOut, 1, 3, emphasizedDecel, popin 90%" + "windowsMove, 1, 3, emphasizedDecel, slide" + "border, 1, 10, emphasizedDecel" + # layers + "layersIn, 1, 2.7, emphasizedDecel, popin 93%" + "layersOut, 1, 2.4, menu_accel, popin 94%" + # fade + "fadeLayersIn, 1, 0.5, menu_decel" + "fadeLayersOut, 1, 2.7, menu_accel" + "fade, 1, 2, emphasizedDecel" + # workspaces + "workspaces, 1, 7, menu_decel, slide" + ## specialWorkspace + "specialWorkspaceIn, 1, 2.8, emphasizedDecel, slidevert" + "specialWorkspaceOut, 1, 1.2, emphasizedAccel, slidevert" + ]; + }; + }; + }; +} + diff --git a/home/hyprland/default.nix b/home/hyprland/default.nix new file mode 100644 index 0000000..16a7d57 --- /dev/null +++ b/home/hyprland/default.nix @@ -0,0 +1,29 @@ +{ inputs, pkgs, ... }: +{ + programs.kitty.enable = true; # required for the default Hyprland config + wayland.windowManager.hyprland = { + enable = true; + # set the flake package + package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; + # make sure to also set the portal package, so that they are in sync + portalPackage = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland; + systemd.enable = true; + }; + + imports = [ + ./animations.nix + ./execs.nix + ./general.nix + ./hypridle.nix + ./input.nix + ./keybinds.nix + ./misc.nix + ./monitors.nix + ./theme.nix + ./rules/windows.nix + ./rules/workspaces.nix + ]; + +# xdg.configFile."hypr".source = ./hypr; +# home.sessionVariables.NIXOS_OZONE_WL = "1"; +} diff --git a/home/hyprland/execs.nix b/home/hyprland/execs.nix new file mode 100644 index 0000000..f39eec5 --- /dev/null +++ b/home/hyprland/execs.nix @@ -0,0 +1,17 @@ +{ + wayland.windowManager.hyprland = { + settings = { + exec-once = [ + "sleep 2; uwsm-app -- vesktop-portable" + # todo openrgb + "sleep 5; uwsm-app -- spotify" + "uwsm-app -- dms run" + "sleep 5; uwsm-app -- Artemis.UI.Linux --minimized" + "sleep 10; bash /home/lilly/Scripts/rgb-on.sh" + # todo sunshine + # todo arrpc + #todo hyprpolkit + ]; + }; + }; +} diff --git a/home/hyprland/general.nix b/home/hyprland/general.nix new file mode 100644 index 0000000..4a338db --- /dev/null +++ b/home/hyprland/general.nix @@ -0,0 +1,45 @@ +{ + wayland.windowManager.hyprland = + { + settings = + { + general = { + no_focus_fallback = true; + allow_tearing = true; + snap = { + enabled = true; + window_gap = 4; + monitor_gap = 5; + respect_gaps = true; + }; + }; + + + dwindle = { + preserve_split = true; + smart_split = false; + smart_resizing = true; + # precise_mouse_move = true; + }; + + render = { + cm_enabled = true; + cm_fs_passthrough = 2; + direct_scanout = 2; + cm_auto_hdr = 1; + }; + + quirks = { + prefer_hdr = 2; + }; + + debug = { + disable_logs = false; + }; + + xwayland = { + force_zero_scaling = true; # Unscale XWayland + }; + }; + }; +} \ No newline at end of file diff --git a/home/hyprland/hypridle.nix b/home/hyprland/hypridle.nix new file mode 100644 index 0000000..a6580ca --- /dev/null +++ b/home/hyprland/hypridle.nix @@ -0,0 +1,20 @@ +{ + services.hypridle = { + enable = true; + systemdTarget = "hyprland-session.target"; + settings = { + general = { + after_sleep_cmd = "hyprctl dispatch dpms on"; + ignore_dbus_inhibit = false; + lock_cmd = "hyprlock"; + }; + listener = [ + { + timeout = 300; # 2mins + on-timeout = "hyprctl dispatch dpms off"; + on-resume = "hyprctl dispatch dpms on"; + } + ]; + }; + }; +} \ No newline at end of file diff --git a/home/hyprland/input.nix b/home/hyprland/input.nix new file mode 100644 index 0000000..317b5ad --- /dev/null +++ b/home/hyprland/input.nix @@ -0,0 +1,18 @@ +{ + wayland.windowManager.hyprland = { + settings = { + input = { + kb_layout = "us"; + kb_variant = "altgr-intl"; + sensitivity = 0.3; + follow_mouse = 1; + accel_profile = "flat"; + + repeat_delay = 250; + repeat_rate = 35; + + off_window_axis_events = 2; + }; + }; + }; +} \ No newline at end of file diff --git a/home/hyprland/keybinds.nix b/home/hyprland/keybinds.nix new file mode 100644 index 0000000..1080f46 --- /dev/null +++ b/home/hyprland/keybinds.nix @@ -0,0 +1,158 @@ +{ + wayland.windowManager.hyprland = { + settings = { + "$mod" = "SUPER"; + + bind = [ + "$mod, space, exec, dms ipc call spotlight toggle" + "alt, space, exec, dms ipc call spotlight toggle" + "$mod, Super_L, exec, dms ipc call spotlight toggle" + # Color Picker + "$mod+Shift, C, exec, hyprpicker -a" # Pick color (Hex) >> clipboard + + # Screenshots + "Super+Shift, S, exec, hyprshot --freeze --mode region --silent --clipboard-only" + "CTRL+Shift, 4, exec, bash /home/lilly/Scripts/zipline-region.sh" + "CTRL+Shift, 3, exec, /home/lilly/Scripts/zipline-monitor.sh" + "CTRL+Shift, 2, exec, /home/lilly/Scripts/zipline-window.sh" + #bindln = Ctrl,Print,exec,grim - | wl-copy Screenshot >> clipboard & file (clipboard) + + #! + ##! Window + #/# bind = $mod, ←/↑/→/↓,, # Focus in direction + "$mod, Left, movefocus, l" + "$mod, Right, movefocus, r" + "$mod, Up, movefocus, u" + "$mod, Down, movefocus, d" + "$mod, BracketLeft, movefocus, l" + "$mod, BracketRight, movefocus, r" + #/# bind = $mod+Shift, ←/↑/→/↓,, # Move in direction + "$mod+Shift, Left, movewindow, l" + "$mod+Shift, Right, movewindow, r" + "$mod+Shift, Up, movewindow, u" + "$mod+Shift, Down, movewindow, d" + "Alt, F4, killactive, Close (Windows)" + "$mod, Q, killactive," # Close + "$mod+Shift+Alt, Q, exec, hyprctl kill" # Forcefully zap a window + + # Window split ratio + #/# binde = Super, ;/',, # Adjust split ratio + # Positioning mode + "Super+Alt, Space, togglefloating," # Float/Tile + "Super, D, fullscreen, 1" # Maximize + "Super, F, fullscreen, 0" # Fullscreen + "Super+Alt, F, fullscreenstate, 0 3" # Fullscreen spoof + "Super, P, pin" # Pin + + #/# bind = Super+Alt, Hash,, # Send to workspace # (1, 2, 3,...) + # We use raw keycodes because some keyboard layouts register number keys as different chars. The codes can be verified with `wev` + "Super+Alt, code:10, movetoworkspacesilent, 1" + "Super+Alt, code:11, movetoworkspacesilent, 2" + "Super+Alt, code:12, movetoworkspacesilent, 3" + "Super+Alt, code:13, movetoworkspacesilent, 4" + "Super+Alt, code:14, movetoworkspacesilent, 5" + "Super+Alt, code:15, movetoworkspacesilent, 6" + "Super+Alt, code:16, movetoworkspacesilent, 7" + "Super+Alt, code:17, movetoworkspacesilent, 8" + "Super+Alt, code:18, movetoworkspacesilent, 9" + "Super+Alt, code:19, movetoworkspacesilent, 10" + + # #/# bind = Super+Shift, Scroll ↑/↓,, # Send to workspace left/right + "Super+Shift, mouse_down, movetoworkspace, r-1" + "Super+Shift, mouse_up, movetoworkspace, r+1" + "Super+Alt, mouse_down, movetoworkspace, -1" + "Super+Alt, mouse_up, movetoworkspace, +1" + + #/# bind = Super+Shift, Page_↑/↓,, # Send to workspace left/right + "Super+Alt, Page_Down, movetoworkspace, +1" + "Super+Alt, Page_Up, movetoworkspace, -1" + "Super+Shift, Page_Down, movetoworkspace, r+1 " + "Super+Shift, Page_Up, movetoworkspace, r-1" + "Ctrl+Super+Shift, Right, movetoworkspace, r+1" + "Ctrl+Super+Shift, Left, movetoworkspace, r-1" + + "Super+Alt, S, movetoworkspacesilent, special" # Send to scratchpad + + "Ctrl+Super, S, togglespecialworkspace," + + ##! Workspace + # Switching + #/# bind = Super, Hash,, # Focus workspace # (1, 2, 3,...) + # We use raw keycodes because some keyboard layouts register number keys as different chars. The codes can be verified with `wev` + "Super, code:10, workspace, 1" + "Super, code:11, workspace, 2" + "Super, code:12, workspace, 3" + "Super, code:13, workspace, 4" + "Super, code:14, workspace, 5" + "Super, code:15, workspace, 6" + "Super, code:16, workspace, 7" + "Super, code:17, workspace, 8" + "Super, code:18, workspace, 9" + "Super, code:19, workspace, 10" + + #/# bind = Ctrl+Super, ←/→,, # Focus left/right + "Ctrl+Super, Right, workspace, r+1" + "Ctrl+Super, Left, workspace, r-1" + #/# bind = Ctrl+Super+Alt, ←/→,, Focus busy left/right + "Ctrl+Super+Alt, Right, workspace, m+1" + "Ctrl+Super+Alt, Left, workspace, m-1" + #/# bind = Super, Page_↑/↓,, # Focus left/right + "Super, Page_Down, workspace, +1" + "Super, Page_Up, workspace, -1" + "Ctrl+Super, Page_Down, workspace, r+1" + "Ctrl+Super, Page_Up, workspace, r-1" + #/# bind = Super, Scroll ↑/↓,, # Focus left/right + "Super, mouse_up, workspace, +1" + "Super, mouse_down, workspace, -1" + "Ctrl+Super, mouse_up, workspace, r+1" + "Ctrl+Super, mouse_down, workspace, r-1" + ## Special + "Ctrl+Super, BracketLeft, workspace, -1" + "Ctrl+Super, BracketRight, workspace, +1" + "Ctrl+Super, Up, workspace, r-5" + "Ctrl+Super, Down, workspace, r+5" + + ##! Apps + "Super, Return, exec, kitty" + "Ctrl+Alt, T, exec, kitty" + "Ctrl+Super, V, exec, pwvucontrol" + "Ctrl+Shift, Escape, exec, \"command -v btop && kitty fish -c btop\"" # Task manager" + + # Cursed stuff + ## Make window not amogus large + "Ctrl+Super, Backslash, resizeactive, exact 640 480" + ]; + + bindle = [ + # Volume / Brightness control + ",XF86MonBrightnessUp, exec, qs -c $qsConfig ipc call brightness increment || brightnessctl s 5%+" + ",XF86MonBrightnessDown, exec, qs -c $qsConfig ipc call brightness decrement || brightnessctl s 5%-" + ",XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%+ -l 1.5" + ",XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%- -l 1.5" + ",XF86AudioMute, exec, wpctl set-mute @DEFAULT_SINK@ toggle" + ]; + + bindm = [ + "$mod, mouse:272, movewindow" + "$mod, mouse:274, movewindow" + "$mod, mouse:273, resizewindow" + ]; + + binde = [ + "Super, Semicolon, splitratio, -0.1" + "Super, Apostrophe, splitratio, +0.1" + ]; + + binds = { + scroll_event_delay = 0; + hide_special_on_workspace_change = true; + }; + + cursor = { + zoom_factor = 1; + zoom_rigid = false; + hotspot_padding = 1; + }; + }; + }; +} diff --git a/home/hyprland/misc.nix b/home/hyprland/misc.nix new file mode 100644 index 0000000..33ed157 --- /dev/null +++ b/home/hyprland/misc.nix @@ -0,0 +1,25 @@ +{ + wayland.windowManager.hyprland = { + settings = { + misc = { + disable_hyprland_logo = true; + disable_splash_rendering = true; + vrr = 3; + vfr = true; + mouse_move_enables_dpms = true; + key_press_enables_dpms = true; + animate_manual_resizes = false; + animate_mouse_windowdragging = false; + enable_swallow = false; + swallow_regex = "(foot|kitty|allacritty|Alacritty)"; + # new_window_takes_over_fs = 2; + allow_session_lock_restore = true; + session_lock_xray = true; + initial_workspace_tracking = false; + middle_click_paste = false; + focus_on_activate = true; + size_limits_tiled = true; + }; + }; + }; +} \ No newline at end of file diff --git a/home/hyprland/monitors.nix b/home/hyprland/monitors.nix new file mode 100644 index 0000000..726245d --- /dev/null +++ b/home/hyprland/monitors.nix @@ -0,0 +1,62 @@ +{ + wayland.windowManager.hyprland = { + settings = { + monitor = [ + ",preferred,auto,1" + ]; + source = [ "monitors.conf" ]; + # monitorv2 = [ + # { + # output = "desc:GIGA-BYTE TECHNOLOGY CO. LTD. AORUS FO32U2 0x01010101"; + # mode = "3840x2160@240.0"; + # position = "0x0"; + # scale = 1.5; + # bitdepth = 10; + # vrr = 3; + # supports_wide_color = 1; + # supports_hdr = 1; + # sdr_min_luminance = 0.000; + # sdr_max_luminance = 1000; + # min_luminance = 0.000; + # max_luminance = 1000; + # max_avg_luminance = 400; + # cm = "hdr"; + # } + # { + # output = "desc:Samsung Electric Company LF32TU87 HNTT700129"; + # mode = "3840x2160@60.0"; + # position = "-2560x0"; + # scale = 1.5; + # bitdepth = 10; + # } + # { + # output = "desc:Technical Concepts Ltd Beyond TV 0x00010000"; + # disabled = true; + # } + # ]; + }; + }; +} + +# monitorv2 { +# output = desc:Technical Concepts Ltd Beyond TV 0x00010000 +# mode = 3840x2160@120.00 +# position = 2560x270 +# scale = 1.5 +# bitdepth = 10 +# vrr = 1 +# supports_wide_color = 1 +# supports_hdr = 1 +# sdr_min_luminance = 0.0005 +# sdr_max_luminance = 2000 +# min_luminance = 0.0005 +# max_luminance = 2000 +# max_avg_luminance = 400 +# cm = hdr +# } + +# workspace = 21, monitor:desc:Technical Concepts Ltd Beyond TV 0x00010000, default:true + +# windowrule = match:class $games, workspace 21, fullscreen on +# # windowrule = fullscreen, class:$games +# windowrule = match:class steam, match:title (Steam Big Picture Mode), workspace 21 \ No newline at end of file diff --git a/home/hyprland/rules/windows.nix b/home/hyprland/rules/windows.nix new file mode 100644 index 0000000..ced4d61 --- /dev/null +++ b/home/hyprland/rules/windows.nix @@ -0,0 +1,101 @@ +{ + wayland.windowManager.hyprland = { + settings = { + "$games" = "^(steam_app_.*|gamescope|starrail.exe|.*\.exe)$"; + "$launch_on_second_monitor" = "^(vesktop|spotify)$"; + "$utility_workspace" = 10; + + windowrule = [ + + # Windows to launch silently on secondary monitor + + "match:class $launch_on_second_monitor, workspace $altscreenworkspace silent" + "match:class steam, match:title Steam, workspace 4 silent, tile on" + + # Launch Steam Friends List as floating window on workspace 4 + + "match:class steam, match:title (Friends List), workspace 4 silent, tile on" + + "match:class $games, content game" + "match:class $games, tag +game" + "match:class $games, workspace 3" + + # Disable VRR for Where Winds meet + "match:class (steam_app_3564740), no_vrr on" + + # Game Stuff + "match:class (starrail\.exe), render_unfocused on" + + # Utilities to silently launch on the last workspace + "match:class (com.github.wwmm.easyeffects), workspace $utility_workspace silent" + "match:class (org.openrgb.OpenRGB), workspace $utility_workspace silent" + "match:class (com.core447.StreamController), match:title StreamController, workspace $utility_workspace silent" + "match:class (opendeck), workspace $utility_workspace silent" + "match:class (Artemis.UI.Linux), match:title (Artemis 2.0), workspace $utility_workspace silent" + + # Focus popups in the center + # Floating + "match:title ^(Open File)(.*)$, center on" + "match:title ^(Open File)(.*)$, float on" + "match:title ^(Select a File)(.*)$, center on" + "match:title ^(Select folder)(.*)$, float on" + "match:title ^(Select folder)(.*)$, center on" + "match:title ^(Select a File)(.*)$, float on" + "match:title ^(Choose wallpaper)(.*)$, center on" + "match:title ^(Choose wallpaper)(.*)$, float on" + "match:title ^(Choose wallpaper)(.*)$, size 60% 65%" + "match:title ^(Open Folder)(.*)$, center on" + "match:title ^(Open Folder)(.*)$, float on" + "match:title ^(Save As)(.*)$, center on" + "match:title ^(Save As)(.*)$, float on" + "match:title ^(Enter name of file to save to)(.*)$, center on" + "match:title ^(Enter name of file to save to)(.*)$, float on" + "match:title ^(Library)(.*)$, center on" + "match:title ^(Library)(.*)$, float on" + "match:title ^(File Upload)(.*)$, center on" + "match:title ^(File Upload)(.*)$, float on" + "match:title ^(.*)(wants to save)$, center on" + "match:title ^(.*)(wants to save)$, float on" + "match:title ^(.*)(wants to open)$, center on" + "match:title ^(.*)(wants to open)$, float on" + "match:class ^(blueberry\.py)$, float on" + "match:class ^(guifetch)$, float on" + "match:class ^(pwvucontrol)$, float on" + "match:class ^(pwvucontrol)$, size 45%" + "match:class ^(pwvucontrol)$, center on" + "match:class ^(com.saivert.pwvucontrol)$, float on" + "match:class ^(com.saivert.pwvucontrol)$, size 45%" + "match:class ^(com.saivert.pwvucontrol)$, center on" + "match:class .*plasmawindowed.*, float on" + "match:class kcm_.*, float on" + "match:class .*bluedevilwizard, float on" + "match:title .*Welcome, float on" + "match:title .*Shell conflicts.*, float on" + "match:class org.freedesktop.impl.portal.desktop.kde, float on" + "match:class org.freedesktop.impl.portal.desktop.kde, size 60% 65%" + "match:class ^(Zotero)$, float on" + "match:class ^(Zotero)$, size 45%" + + # stupid dolphin copy + "match:title ^(Copying — Dolphin)$, move 40 80" + + # Picture-in-Picture + "match:title ^([Pp]icture[-\s]?[Ii]n[-\s]?[Pp]icture)(.*)$, float on" + "match:title ^([Pp]icture[-\s]?[Ii]n[-\s]?[Pp]icture)(.*)$, keep_aspect_ratio on" + "match:title ^([Pp]icture[-\s]?[Ii]n[-\s]?[Pp]icture)(.*)$, move 73% 72%" + "match:title ^([Pp]icture[-\s]?[Ii]n[-\s]?[Pp]icture)(.*)$, size 25%" + "match:title ^([Pp]icture[-\s]?[Ii]n[-\s]?[Pp]icture)(.*)$, pin on" + + # --- Tearing --- + "match:class $games, immediate on" + + # No shadow for tiled windows (matches windows that are not floating). + "match:float 0, no_shadow on" + + # Prevent Idle while fullscreen + "match:class (.*), idle_inhibit fullscreen" + ]; + }; + }; +} + diff --git a/home/hyprland/rules/workspaces.nix b/home/hyprland/rules/workspaces.nix new file mode 100644 index 0000000..fb7fbca --- /dev/null +++ b/home/hyprland/rules/workspaces.nix @@ -0,0 +1,33 @@ +{ + wayland.windowManager.hyprland = { + settings = { + "$altscreenworkspace" = "11"; + "$mainmonitor" = "GIGA-BYTE TECHNOLOGY CO. LTD. AORUS FO32U2 24210B000546"; + + workspace = [ + "1, monitor:desc:$mainmonitor, default:true" + "2, monitor:desc:$mainmonitor" + "3, monitor:desc:$mainmonitor" + "4, monitor:desc:$mainmonitor" + "5, monitor:desc:$mainmonitor" + "6, monitor:desc:$mainmonitor" + "7, monitor:desc:$mainmonitor" + "8, monitor:desc:$mainmonitor" + "9, monitor:desc:$mainmonitor" + "10, monitor:desc:$mainmonitor" + + "$altscreenworkspace, monitor:desc:Samsung Electric Company LF32TU87 HNTT700129, default:true" + "$altscreenworkspace, layoutopt:orientation:bottom" + + "21, monitor:desc:Technical Concepts Ltd Beyond TV 0x00010000, default:true" + + # ######## Workspace rules ######## + "special:special, gapsout:30" + ]; + + # Launchers need to be FAST + layerrule = [ "match:namespace gtk4-layer-shell, no_anim on" ]; + }; + }; +} + diff --git a/home/hyprland/theme.nix b/home/hyprland/theme.nix new file mode 100644 index 0000000..9fd8afd --- /dev/null +++ b/home/hyprland/theme.nix @@ -0,0 +1,50 @@ +{ + wayland.windowManager.hyprland = { + settings = { + general = { + gaps_in = 5; + gaps_out = 5; + border_size = 0; + + #"col.active_border" = "rgba(707070ff)"; + #"col.inactive_border" = "rgba(d0d0d0ff)"; + layout = "dwindle"; + }; + + decoration = { + rounding = 12; + active_opacity = 1.0; + shadow = { + enabled = true; + range = 30; + render_power = 5; + offset = "0 5"; + color = "rgba(00000070)"; + }; + }; + + # Opacity for inactive windows + # windowrulev2 = opacity 0.9 0.9, floating:0, focus:0 + + windowrule = [ + # GNOME apps + "match:class ^(org\.gnome\.), rounding 12" + "match:class ^(org\.gnome\.), border_size 0" + + # Terminal apps - no borders + "match:class ^(org\.wezfurlong\.wezterm)$, border_size 0" + "match:class ^(Alacritty)$, border_size 0" + "match:class ^(zen)$, border_size 0" + "match:class ^(com\.mitchellh\.ghostty)$, border_size 0" + "match:class ^(kitty)$, border_size 0" + + # Floating windows + "match:class ^(gnome-calculator)$, float true" + "match:class ^(blueman-manager)$, float true" + "match:class ^(org\.gnome\.Nautilus)$, float true" + ]; + # Quickshell animation + layerrule = [ "match:namespace ^(quickshell)$, no_anim on" ]; + }; + }; +} diff --git a/home/spicetify.nix b/home/spicetify.nix new file mode 100644 index 0000000..01d8962 --- /dev/null +++ b/home/spicetify.nix @@ -0,0 +1,33 @@ +{ inputs, pkgs, ... }: +{ + imports = [ + inputs.spicetify-nix.homeManagerModules.default + ]; + programs.spicetify = + let + spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.stdenv.hostPlatform.system}; + in + { + enable = true; + + enabledExtensions = with spicePkgs.extensions; [ + hidePodcasts + shuffle # shuffle+ (special characters are sanitized out of extension names) + betterGenres + lastfm + adblock + beautifulLyrics + aiBandBlocker + ]; + enabledCustomApps = with spicePkgs.apps; [ + lyricsPlus + betterLibrary + newReleases + ]; + enabledSnippets = with spicePkgs.snippets; [ + pointer + ]; + theme = spicePkgs.themes.catppuccin; + colorScheme = "mocha"; + }; +} diff --git a/home/terminal/btop.nix b/home/terminal/btop.nix new file mode 100644 index 0000000..017da5a --- /dev/null +++ b/home/terminal/btop.nix @@ -0,0 +1,10 @@ +{ pkgs, ... }: +{ + programs.btop = { + enable = true; + package = pkgs.btop.override { + cudaSupport = true; + rocmSupport = true; + }; + }; +} diff --git a/home/terminal/default.nix b/home/terminal/default.nix new file mode 100644 index 0000000..18ed1e6 --- /dev/null +++ b/home/terminal/default.nix @@ -0,0 +1,20 @@ +{ lib, ... }: +let + b = builtins; + + module_files = + b.readDir ./. |> + lib.filterAttrs (name: type: + ( (lib.strings.hasSuffix ".nix" name + && name != "default.nix" + && type == "regular" ) + || ( type == "directory" + && b.pathExists ./${name}/default.nix)) + ) |> + b.attrNames |> + b.map (f: ./${f}); +in +{ + imports = module_files; + nixpkgs.config.allowUnfree = true; +} \ No newline at end of file diff --git a/home/terminal/eza.nix b/home/terminal/eza.nix new file mode 100644 index 0000000..63de65a --- /dev/null +++ b/home/terminal/eza.nix @@ -0,0 +1,30 @@ +# Eza is a ls replacement +{ + programs.eza = { + enable = true; + icons = "auto"; + enableBashIntegration = true; + enableZshIntegration = true; + enableFishIntegration = true; + git = true; + + extraOptions = [ + "--group-directories-first" + "--no-quotes" + "--header" # Show header row + "--git-ignore" + "--icons=always" + # "--time-style=long-iso" # ISO 8601 extended format for time + "--classify" # append indicator (/, *, =, @, |) + "--hyperlink" # make paths clickable in some terminals + ]; + }; + # Aliases to make `ls`, `ll`, `la` use eza + home.shellAliases = { + ls = "eza"; + lt = "eza --tree --level=2"; + ll = "eza -lh --no-user --long"; + la = "eza -lah "; + tree = "eza --tree "; + }; +} diff --git a/home/terminal/fish.nix b/home/terminal/fish.nix new file mode 100644 index 0000000..ac139b4 --- /dev/null +++ b/home/terminal/fish.nix @@ -0,0 +1,25 @@ +{ + pkgs, + host, + ... +}: { + programs.fish = { + enable = true; + shellAliases = { + fr = "sudo nixos-rebuild switch --flake ~/LillyOS/#${host}"; + }; + interactiveShellInit = '' + set fish_greeting # Disable greeting + ''; + plugins = [ + # Enable a plugin (here grc for colorized command output) from nixpkgs + { name = "grc"; src = pkgs.fishPlugins.grc.src; } + { name = "tide"; src = pkgs.fishPlugins.tide.src; } + { name = "done"; src = pkgs.fishPlugins.done.src; } + { name = "fish-you-should-use"; src = pkgs.fishPlugins.fish-you-should-use.src; } + { name = "autopair"; src = pkgs.fishPlugins.autopair.src; } + { name = "fzf-fish"; src = pkgs.fishPlugins.fzf-fish.src; } + { name = "git-abbr"; src = pkgs.fishPlugins.git-abbr.src; } + ]; + }; +} diff --git a/home/terminal/git.nix b/home/terminal/git.nix new file mode 100644 index 0000000..dc1e3d9 --- /dev/null +++ b/home/terminal/git.nix @@ -0,0 +1,22 @@ +{ email, prettyUsername, ... }: +{ + programs.git = { + enable = true; + + settings = { + user = { + name = "${prettyUsername}"; + email = "${email}"; + }; + + # FOSS-friendly settings + push.default = "simple"; # Match modern push behavior + credential.helper = "cache --timeout=7200"; + init.defaultBranch = "main"; # Set default new branches to 'main' + log.decorate = "full"; # Show branch/tag info in git log + log.date = "iso"; # ISO 8601 date format + # Conflict resolution style for readable diffs + merge.conflictStyle = "diff3"; + }; + }; +} \ No newline at end of file diff --git a/home/terminal/kitty.nix b/home/terminal/kitty.nix new file mode 100644 index 0000000..0a19899 --- /dev/null +++ b/home/terminal/kitty.nix @@ -0,0 +1,97 @@ +{ + pkgs, + ... +}: { + programs.kitty = { + enable = true; + + # Upstream test failures resolved; use default kitty package (>= 0.44). + package = pkgs.kitty; + settings = { + font_family = "Maple Mono NF"; + font_size = 11; + wheel_scroll_min_lines = 1; + window_padding_width = 4; + confirm_os_window_close = 0; + scrollback_lines = 10000; + enable_audio_bell = false; + mouse_hide_wait = 60; + cursor_trail = 1; + cursor_shape = "beam"; + tab_fade = 1; + active_tab_font_style = "bold"; + inactive_tab_font_style = "bold"; + tab_bar_edge = "top"; + tab_bar_margin_width = 0; + tab_bar_style = "powerline"; + #tab_bar_style = "fade"; + enabled_layouts = "splits"; + open_url_with_default = true; + detect_urls = true; + allow_remote_control = true; + shell = "fish"; + }; + + shellIntegration.enableZshIntegration = true; + shellIntegration.enableFishIntegration = true; + shellIntegration.enableBashIntegration = true; + shellIntegration.mode = "enabled"; + + extraConfig = '' + + #open_url_with default + url_prefixes file ftp ftps gemini git gopher http https irc ircs kitty sftp ssh + #detect_urls yes + + # Clipboard + #map ctrl+shift+v paste_from_selection + #map shift+insert paste_from_selection + + # Scrolling + map ctrl+shift+up scroll_line_up + map ctrl+shift+down scroll_line_down + map ctrl+shift+k scroll_line_up + map ctrl+shift+j scroll_line_down + map ctrl+shift+page_up scroll_page_up + map ctrl+shift+page_down scroll_page_down + map ctrl+shift+home scroll_home + map ctrl+shift+end scroll_end + map ctrl+shift+h show_scrollback + + # Window management + map alt+n new_window_with_cwd + #map alt+n new_os_window + map alt+w close_window + map ctrl+shift+enter launch --location=hsplit + map ctrl+shift+s launch --location=vsplit + map ctrl+shift+] next_window + map ctrl+shift+[ previous_window + map ctrl+shift+f move_window_forward + map ctrl+shift+b move_window_backward + map ctrl+shift+` move_window_to_top + map ctrl+shift+1 first_window + map ctrl+shift+2 second_window + map ctrl+shift+3 third_window + map ctrl+shift+4 fourth_window + map ctrl+shift+5 fifth_window + map ctrl+shift+6 sixth_window + map ctrl+shift+7 seventh_window + map ctrl+shift+8 eighth_window + map ctrl+shift+9 ninth_window # Tab management + map ctrl+shift+0 tenth_window + map ctrl+shift+right next_tab + map ctrl+shift+left previous_tab + map ctrl+shift+t new_tab + map ctrl+shift+q close_tab + map ctrl+shift+l next_layout + map ctrl+shift+. move_tab_forward + map ctrl+shift+, move_tab_backward + + # Miscellaneous + map ctrl+shift+up increase_font_size + map ctrl+shift+down decrease_font_size + map ctrl+shift+backspace restore_font_size + ''; + }; + +} diff --git a/home/terminal/zoxide.nix b/home/terminal/zoxide.nix new file mode 100644 index 0000000..153d85c --- /dev/null +++ b/home/terminal/zoxide.nix @@ -0,0 +1,12 @@ +_: { + programs = { + zoxide = { + enable = true; + enableZshIntegration = true; + enableBashIntegration = true; + options = [ + "--cmd cd" + ]; + }; + }; +} diff --git a/home/vesktop.nix b/home/vesktop.nix new file mode 100644 index 0000000..00afa0c --- /dev/null +++ b/home/vesktop.nix @@ -0,0 +1,104 @@ +{ pkgs, username, ... }: +{ + home.packages = [ + (pkgs.writeShellScriptBin "vesktop-portable" '' + exec /home/${username}/vesktop/vesktop --ozone-platform-hint=auto --enable-features=WaylandWindowDecorations --enable-wayland-ime=true --enable-blink-features=MiddleClickAutoscroll "$@" + '') + ]; + xdg.desktopEntries.vesktop = { + name = "Vesktop"; + genericName = "Discord Client"; + exec = "vesktop-portable %U"; + icon = "vesktop"; + terminal = false; + categories = [ "Network" "InstantMessaging" "Chat" ]; + }; + + programs.vesktop = { + enable = true; + package = pkgs.vesktop.override { + withMiddleClickScroll = true; + }; + settings = { + arRPC = true; + tray = true; + minimizeToTray = true; + }; + vencord = { + settings = { + plugins = { + AlwaysTrust.enabled = true; + BetterSessions.enabled = true; + BetterSettings.enabled = true; + BiggerStreamPreview.enabled = true; + CallTimer.enabled = true; + ClearURLs.enabled = true; + CopyEmojiMarkdown.enabled = true; + CopyFileContents.enabled = true; + CopyUserURLs.enabled = true; + CrashHandler.enabled = true; + CustomIdle = { + enabled = true; + idleTimeout = 0; + remainInIdle = false; + }; + Dearrow.enabled = true; + DisableCallIdle.enabled = true; + ExpressionCloner.enabled = true; + FavoriteEmojiFirst.enabled = true; + FixSpotifyEmbeds.enabled = true; + FixYoutubeEmbeds.enabled = true; + FullSearchContext.enabled = true; + GameActivityToggle.enabled = true; + GifPaste.enabled = true; + ImageZoom.enabled = true; + LoadingQuotes.enabled = true; + MemberCount.enabled = true; + MentionAvatars.enabled = true; + MessageLinkEmbeds.enabled = true; + MessageLogger = { + enabled = true; + inlineEdits = false; + }; + NewGuildSettings.enabled = true; + NoF1.enabled = true; + NoOnboardingDelay.enabled = true; + NormalizeMessageLinks.enabled = true; + NoUnblockToJump.enabled = true; + OnePingPerDm.enabled = true; + OpenInApp.enabled = true; + petpet.enabled = true; + ReadAllNotificationsButton.enabled = true; + RelationshipNotifier.enabled = true; + ReverseImageSearch.enabled = true; + ServerInfo.enabled = true; + ServerListIndicators.enabled = false; + ShowHiddenChannels.enabled = true; + ShowHiddenThings.enabled = true; + SpotifyControls.enabled = true; + ThemeAttributes.enabled = true; + TypingIndicator.enabled = true; + TypingTweaks.enabled = true; + UnlockedAvatarZoom.enabled = true; + UnsuppressEmbeds.enabled = true; + UserVoiceShow.enabled = true; + ValidUser.enabled = true; + ViewIcons.enabled = true; + ViewRaw.enabled = true; + VoiceChatDoubleClick.enabled = true; + VoiceDownload.enabled = true; + VoiceMessages.enabled = true; + WebKeybinds.enabled = true; + WebScreenShareFixes.enabled = true; + WhoReacted.enabled = true; + YoutubeAdblock.enabled = true; + DisableDeepLinks.enabled = true; + NoTrack.enabled = true; + Settings.enabled = true; + SupportHelper.enabled = true; + WebContextMenus.enabled = true; + }; + }; + }; + }; +} diff --git a/home/vscode.nix b/home/vscode.nix new file mode 100644 index 0000000..fb2674d --- /dev/null +++ b/home/vscode.nix @@ -0,0 +1,11 @@ +{ pkgs, ... }: +{ + programs.vscode = { + enable = true; + profiles.default.extensions = with pkgs.vscode-extensions; [ + jnoortheen.nix-ide + catppuccin.catppuccin-vsc-icons + catppuccin.catppuccin-vsc + ]; + }; +} diff --git a/home/xdg-config/default.nix b/home/xdg-config/default.nix new file mode 100644 index 0000000..18ed1e6 --- /dev/null +++ b/home/xdg-config/default.nix @@ -0,0 +1,20 @@ +{ lib, ... }: +let + b = builtins; + + module_files = + b.readDir ./. |> + lib.filterAttrs (name: type: + ( (lib.strings.hasSuffix ".nix" name + && name != "default.nix" + && type == "regular" ) + || ( type == "directory" + && b.pathExists ./${name}/default.nix)) + ) |> + b.attrNames |> + b.map (f: ./${f}); +in +{ + imports = module_files; + nixpkgs.config.allowUnfree = true; +} \ No newline at end of file diff --git a/home/xdg-config/electron-flags.nix b/home/xdg-config/electron-flags.nix new file mode 100644 index 0000000..03ffb1f --- /dev/null +++ b/home/xdg-config/electron-flags.nix @@ -0,0 +1,17 @@ +{ + xdg.configFile."electron-flags.conf".text = '' +--enable-features=WaylandWindowDecorations +--ozone-platform-hint=wayland +--enable-blink-features=MiddleClickAutoscroll +--ozone-platform=wayland + ''; + xdg.configFile."code-flags.conf".text = '' +--ozone-platform-hint=wayland +--ozone-platform=wayland +--gtk-version=4 +--ignore-gpu-blocklist +--enable-features=TouchpadOverscrollHistoryNavigation +--enable-wayland-ime +--password-store=gnome-libsecret + ''; +} \ No newline at end of file diff --git a/home/xdg-config/mime.nix b/home/xdg-config/mime.nix new file mode 100644 index 0000000..af52f9f --- /dev/null +++ b/home/xdg-config/mime.nix @@ -0,0 +1,14 @@ +let + gwenview_desktop_file = "org.kde.gwenview.desktop"; +in + let + associations = { + "image/jpeg" = "${gwenview_desktop_file}"; + }; + in + { + xdg.mimeApps = { + associations.added = associations; + defaultApplications = associations; + }; + } \ No newline at end of file diff --git a/home/xdg-config/uwsm-env.nix b/home/xdg-config/uwsm-env.nix new file mode 100644 index 0000000..08de24f --- /dev/null +++ b/home/xdg-config/uwsm-env.nix @@ -0,0 +1,40 @@ +{ + xdg.configFile."uwsm/env".text = '' +export GDK_BACKEND=wayland,x11,* +export GDK_SCALE=2 # GDK Scaling Factor (no fractional scaling) + +export MOZ_ENABLE_WAYLAND=1 +export MOZ_DISABLE_RDD_SANDBOX=1 + +export OZONE_PLATFORM=wayland + +export ELECTRON_OZONE_PLATFORM_HINT=auto + +export SDL_VIDEODRIVER=wayland +export CLUTTER_BACKEND=wayland + +export QT_QPA_PLATFORM=wayland;xcb +export QT_QPA_PLATFORMTHEME=qt5ct +export XDG_MENU_PREFIX=plasma- +export QT_QPA_PLATFORMTHEME_QT6=qt5ct +export GTK_THEME=Adwaita:dark +export QS_ICON_THEME=Papirus-Dark + +export LIBVA_DRIVER_NAME=nvidia +export __GLX_VENDOR_LIBRARY_NAME=nvidia +export XDG_SESSION_DESKTOP=Hyprland +export GBM_BACKEND=nvidia-drm +export TERMINAL=kitty + +export __GL_GSYNC_ALLOWED=1 +export __GL_VRR_ALLOWED=1 + +export EDITOR=code +export STLEDITOR=code + +export XCURSOR_SIZE=16 + ''; + xdg.configFile."uwsm/env-hyprland".text = '' +export AQ_DRM_DEVICES=/dev/dri/nvidia-dgpu + ''; +} diff --git a/home/xdg.nix b/home/xdg.nix new file mode 100644 index 0000000..d088598 --- /dev/null +++ b/home/xdg.nix @@ -0,0 +1,17 @@ +{ pkgs, inputs, ...}: + +{ + xdg = { + enable = true; + mime.enable = true; + mimeApps.enable = true; + portal = { + enable = true; + extraPortals = [ + inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland + pkgs.xdg-desktop-portal-gtk + ]; + configPackages = [inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland]; + }; + }; +} diff --git a/home/zen-browser.nix b/home/zen-browser.nix new file mode 100644 index 0000000..c4d5396 --- /dev/null +++ b/home/zen-browser.nix @@ -0,0 +1,98 @@ +{ inputs, pkgs, ... }: +{ + imports = [ + inputs.zen-browser.homeModules.beta + ]; + home.file."catppuccin-zen" = { + target = ".zen/default/chrome/catppuccin-zen"; + source = ( + fetchTarball { + url = "https://github.com/catppuccin/zen-browser/tarball/c855685442c6040c4dda9c8d3ddc7b708de1cbaa"; + sha256 = "sha256:03ky8s5h9vkw4cp3nm86b0bk5qbjmqgyqq9a95xqzard4wppn3p4"; + }); + }; + programs.zen-browser = { + enable = true; + nativeMessagingHosts = [pkgs.firefoxpwa]; + policies = { + AutofillAddressEnabled = false; + AutofillCreditCardEnabled = false; + DisableAppUpdate = true; + DisableFeedbackCommands = true; + DisableFirefoxStudies = true; + DisablePocket = true; + DisableTelemetry = true; + DontCheckDefaultBrowser = true; + NoDefaultBookmarks = true; + OfferToSaveLogins = false; + EnableTrackingProtection = { + Value = true; + Locked = true; + Cryptomining = true; + Fingerprinting = true; + }; + }; + profiles.default.settings = { + "zen.view.use-single-toolbar" = false; + "zen.urlbar.replace-newtab" = false; + "identity.fxaccounts.autoconfig.uri" = "https://www.fxa.hibana.me"; + "general.autoScroll" = true; + "toolkit.legacyUserProfileCustomizations.stylesheets" = true; + }; + profiles.default.extensions.packages = + with inputs.firefox-addons.packages.${pkgs.stdenv.hostPlatform.system}; [ + ublock-origin + dearrow + bitwarden + istilldontcareaboutcookies + return-youtube-dislikes + sponsorblock + youtube-nonstop + youtube-high-definition + absolute-enable-right-click + augmented-steam + clearurls + darkreader + karakeep + newtab-adapter + steam-database + unpaywall + violentmonkey + ]; + profiles.default.userChrome = '' + @import "catppuccin-zen/themes/Mocha/Mauve/userChrome.css"; + ''; + profiles.default.userContent = '' + @import "catppuccin-zen/themes/Mocha/Mauve/userContent.css"; + ''; + }; + xdg.mimeApps = let + value = let + zen-browser = inputs.zen-browser.packages.${pkgs.stdenv.hostPlatform.system}.beta; # or twilight + in + zen-browser.meta.desktopFileName; + + associations = builtins.listToAttrs (map (name: { + inherit name value; + }) [ + "application/x-extension-shtml" + "application/x-extension-xhtml" + "application/x-extension-html" + "application/x-extension-xht" + "application/x-extension-htm" + "x-scheme-handler/unknown" + "x-scheme-handler/mailto" + "x-scheme-handler/chrome" + "x-scheme-handler/about" + "x-scheme-handler/https" + "x-scheme-handler/http" + "application/xhtml+xml" + "application/json" + "text/plain" + "text/html" + ]); + in { + associations.added = associations; + defaultApplications = associations; + }; +} diff --git a/hosts/lillypc/config.nix b/hosts/lillypc/config.nix new file mode 100644 index 0000000..3ec00d6 --- /dev/null +++ b/hosts/lillypc/config.nix @@ -0,0 +1,23 @@ +{ + my = { + + gaming.enable = true; + + cachyosKernel.enable = true; + + desktop = { + enable = true; + sddm = { + enable = true; + autoLogin.enable = true; + }; + hyprland.enable = true; + flatpak.enable = true; + }; + + nvidia.enable = true; + openlinkhub.enable = true; + rgb.enable = true; + }; + openlinkhub.enable = true; +} diff --git a/hosts/lillypc/default.nix b/hosts/lillypc/default.nix new file mode 100644 index 0000000..09a4da8 --- /dev/null +++ b/hosts/lillypc/default.nix @@ -0,0 +1,19 @@ +{ lib, ... }: +let + b = builtins; + + module_files = + b.readDir ./. |> + lib.filterAttrs (name: type: + ( (lib.strings.hasSuffix ".nix" name + && name != "default.nix" + && type == "regular" ) + || ( type == "directory" + && b.pathExists ./${name}/default.nix)) + ) |> + b.attrNames |> + b.map (f: ./${f}); +in +{ + imports = module_files; +} \ No newline at end of file diff --git a/hosts/lillypc/hardware.nix b/hosts/lillypc/hardware.nix new file mode 100644 index 0000000..a443811 --- /dev/null +++ b/hosts/lillypc/hardware.nix @@ -0,0 +1,44 @@ +# Do not modify this file! It was generated by ‘nixos-generate-config’ +# and may be overwritten by future invocations. Please make changes +# to /etc/nixos/configuration.nix instead. +{ config, lib, modulesPath, ... }: + +{ + imports = + [ (modulesPath + "/installer/scan/not-detected.nix") + ]; + + boot.initrd.availableKernelModules = [ "nvme" "ahci" "thunderbolt" "xhci_pci" "usbhid" "usb_storage" "sd_mod" ]; + boot.initrd.kernelModules = [ ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/8ef1b753-7a4a-4062-a906-6a01ce7b6111"; + fsType = "btrfs"; + options = [ "subvol=@" "rw" "relatime" "compress=zstd:3" "ssd" "discard=async" "space_cache=v2" ]; + }; + + fileSystems."/home" = + { device = "/dev/disk/by-uuid/8ef1b753-7a4a-4062-a906-6a01ce7b6111"; + fsType = "btrfs"; + options = [ "subvol=@home" "rw" "relatime" "compress=zstd:3" "ssd" "discard=async" "space_cache=v2" ]; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/69B8-FDBD"; + fsType = "vfat"; + options = [ "fmask=0077" "dmask=0077" ]; + }; + + fileSystems."/data" = + { device = "/dev/disk/by-uuid/5c58c3c4-2ce8-4ad9-8277-ff7503462f88"; + fsType = "btrfs"; + options = [ "rw" "relatime" "compress=zstd:3" "ssd" "discard=async" "space_cache=v2" ]; + }; + + swapDevices = + [ { device = "/dev/disk/by-uuid/58267d20-fa23-4874-b619-36a263f8be88"; } + ]; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +} diff --git a/hosts/lillypc/openrgb.nix b/hosts/lillypc/openrgb.nix new file mode 100644 index 0000000..028d6d4 --- /dev/null +++ b/hosts/lillypc/openrgb.nix @@ -0,0 +1,5 @@ +{ + systemd.tmpfiles.rules = [ + "L+ /var/lib/OpenRGB/sizes.ors - - - - ${./openrgb/sizes.ors}" + ]; +} \ No newline at end of file diff --git a/hosts/lillypc/openrgb/sizes.ors b/hosts/lillypc/openrgb/sizes.ors new file mode 100644 index 0000000..f20afd0 Binary files /dev/null and b/hosts/lillypc/openrgb/sizes.ors differ diff --git a/hosts/lillypc/share-mounts.nix b/hosts/lillypc/share-mounts.nix new file mode 100644 index 0000000..e760000 --- /dev/null +++ b/hosts/lillypc/share-mounts.nix @@ -0,0 +1,36 @@ +{ pkgs, username, ... }: +#let mount_opts = "x-systemd.automount,user,iocharset=utf8,rw,noauto,nofail,credentials=/etc/nixos/smb-secrets,uid=1000,gid=100"; +let mount_opts = "iocharset=utf8,rw,auto,nofail,credentials=/etc/nixos/smb-secrets,uid=1000,gid=100"; +in { + environment.systemPackages = [ pkgs.cifs-utils ]; + + fileSystems."/home/${username}/Shares/NAS" = { + device = "//10.0.10.5/LillyNAS"; + fsType = "cifs"; + options = [ "${mount_opts}" ]; + }; + + fileSystems."/home/${username}/Shares/3D-Printing" = { + device = "//10.0.10.5/3D-Printing"; + fsType = "cifs"; + options = [ "${mount_opts}" ]; + }; + + fileSystems."/home/${username}/Shares/Media" = { + device = "//10.0.10.5/Media"; + fsType = "cifs"; + options = [ "${mount_opts}" ]; + }; + + fileSystems."/home/${username}/Shares/PaperlessConsume" = { + device = "//10.0.10.5/PaperlessConsume"; + fsType = "cifs"; + options = [ "${mount_opts}" ]; + }; + + fileSystems."/home/${username}/Shares/LillyPhoneSync" = { + device = "//10.0.10.5/LillyPhoneSync"; + fsType = "cifs"; + options = [ "${mount_opts}" ]; + }; +} \ No newline at end of file diff --git a/hosts/lillypc/systemd.nix b/hosts/lillypc/systemd.nix new file mode 100644 index 0000000..bb9833f --- /dev/null +++ b/hosts/lillypc/systemd.nix @@ -0,0 +1,12 @@ +{ pkgs, ... }: +{ + systemd.services.nvidia-undervolt = { + enable = true; + description = "Set NVIDIA GPU undervolt"; + wantedBy = [ "multi-user.target" ]; + serviceConfig = { + Type = "oneshot"; + ExecStart = "${pkgs.nvidia_oc}/bin/nvidia_oc set --index 0 --freq-offset 250"; + }; + }; +} diff --git a/hosts/lillypc/udev.nix b/hosts/lillypc/udev.nix new file mode 100644 index 0000000..20ba7cc --- /dev/null +++ b/hosts/lillypc/udev.nix @@ -0,0 +1,6 @@ +{ + services.udev.extraRules = '' +KERNEL=="card*", KERNELS=="0000:6d:00.0", SUBSYSTEM=="drm", SUBSYSTEMS=="pci", SYMLINK+="dri/amd-igpu" +KERNEL=="card*", KERNELS=="0000:01:00.0", SUBSYSTEM=="drm", SUBSYSTEMS=="pci", SYMLINK+="dri/nvidia-dgpu" + ''; +} \ No newline at end of file diff --git a/modules/cli/adb.nix b/modules/cli/adb.nix new file mode 100644 index 0000000..0995a47 --- /dev/null +++ b/modules/cli/adb.nix @@ -0,0 +1,3 @@ +{ + programs.adb.enable = true; +} \ No newline at end of file diff --git a/modules/cli/btop.nix b/modules/cli/btop.nix new file mode 100644 index 0000000..ca4aa59 --- /dev/null +++ b/modules/cli/btop.nix @@ -0,0 +1,5 @@ +{ + systemd.tmpfiles.rules = [ + "Z /sys/class/powercap/intel-rapl:0/energy_uj 0444 root root - -" + ]; +} \ No newline at end of file diff --git a/modules/cli/default.nix b/modules/cli/default.nix new file mode 100644 index 0000000..09a4da8 --- /dev/null +++ b/modules/cli/default.nix @@ -0,0 +1,19 @@ +{ lib, ... }: +let + b = builtins; + + module_files = + b.readDir ./. |> + lib.filterAttrs (name: type: + ( (lib.strings.hasSuffix ".nix" name + && name != "default.nix" + && type == "regular" ) + || ( type == "directory" + && b.pathExists ./${name}/default.nix)) + ) |> + b.attrNames |> + b.map (f: ./${f}); +in +{ + imports = module_files; +} \ No newline at end of file diff --git a/modules/cli/fish.nix b/modules/cli/fish.nix new file mode 100644 index 0000000..9f00ef6 --- /dev/null +++ b/modules/cli/fish.nix @@ -0,0 +1,17 @@ +{ pkgs, ...}: + +{ + environment.systemPackages = with pkgs; [ + fish + grc + fishPlugins.done + fishPlugins.tide + fishPlugins.sponge + fishPlugins.grc + fishPlugins.fish-you-should-use + fishPlugins.autopair + fishPlugins.async-prompt + fishPlugins.fzf-fish + fishPlugins.git-abbr + ]; +} diff --git a/modules/cli/packages.nix b/modules/cli/packages.nix new file mode 100644 index 0000000..32412f7 --- /dev/null +++ b/modules/cli/packages.nix @@ -0,0 +1,36 @@ +{ pkgs, ...}: + +{ + environment.systemPackages = with pkgs; [ + duf + eza + ffmpeg + htop + killall + libnotify + lm_sensors + lshw + ncdu + pciutils + socat + unrar + unzip + usbutils + v4l-utils + nvtopPackages.full + wget + ytmdl + yt-dlp + python3 + python313Packages.pynvml + python313Packages.py3nvml + git + zip + killall + zoxide + fzf + p7zip + curl + jq + ]; +} diff --git a/modules/corsairLink.nix b/modules/corsairLink.nix new file mode 100644 index 0000000..d75c1c3 --- /dev/null +++ b/modules/corsairLink.nix @@ -0,0 +1,10 @@ +{ config, inputs, ... }: +let + cfg = config.my.openlinkhub; +in +{ + imports = [ + inputs.openlinkhub.nixosModules.default + ]; + openlinkhub.enable = cfg.enable; +} \ No newline at end of file diff --git a/modules/default.nix b/modules/default.nix new file mode 100644 index 0000000..b9c71a9 --- /dev/null +++ b/modules/default.nix @@ -0,0 +1,15 @@ +{ + imports = [ + ./cli + ./packages.nix + ./desktop + ./gaming + ./hardware.nix + ./network.nix + ./services.nix + ./fonts.nix + ./ld.nix + ./nvidia.nix + ./corsairLink.nix + ]; +} diff --git a/modules/desktop/catppuccin.nix b/modules/desktop/catppuccin.nix new file mode 100644 index 0000000..53d4039 --- /dev/null +++ b/modules/desktop/catppuccin.nix @@ -0,0 +1,17 @@ +{ config, pkgs, lib, ... }: + +{ + config = lib.mkIf config.my.desktop.enable { + catppuccin = { + enable = true; + accent = "mauve"; + flavor = "mocha"; + }; + environment.systemPackages = with pkgs; [ + libsForQt5.qtstyleplugin-kvantum + libsForQt5.qt5ct + catppuccin-kvantum + magnetic-catppuccin-gtk + ]; + }; +} \ No newline at end of file diff --git a/modules/desktop/default.nix b/modules/desktop/default.nix new file mode 100644 index 0000000..09a4da8 --- /dev/null +++ b/modules/desktop/default.nix @@ -0,0 +1,19 @@ +{ lib, ... }: +let + b = builtins; + + module_files = + b.readDir ./. |> + lib.filterAttrs (name: type: + ( (lib.strings.hasSuffix ".nix" name + && name != "default.nix" + && type == "regular" ) + || ( type == "directory" + && b.pathExists ./${name}/default.nix)) + ) |> + b.attrNames |> + b.map (f: ./${f}); +in +{ + imports = module_files; +} \ No newline at end of file diff --git a/modules/desktop/dms.nix b/modules/desktop/dms.nix new file mode 100644 index 0000000..c898373 --- /dev/null +++ b/modules/desktop/dms.nix @@ -0,0 +1,26 @@ +{ lib, config, inputs, ... }: +let + cfg = config.my.desktop; +in +{ + imports = [ + inputs.dms.nixosModules.dankMaterialShell + ]; + + programs.dankMaterialShell = lib.mkIf (cfg.enable && cfg.hyprland.enable) { + enable = true; + + systemd = { + enable = false; # Systemd service for auto-start + restartIfChanged = false; # Auto-restart dms.service when dankMaterialShell changes + }; + + # Core features + enableSystemMonitoring = true; # System monitoring widgets (dgop) + enableClipboard = true; # Clipboard history manager + enableVPN = true; # VPN management widget + enableDynamicTheming = true; # Wallpaper-based theming (matugen) + enableAudioWavelength = true; # Audio visualizer (cava) + enableCalendarEvents = true; # Calendar integration (khal) + }; +} diff --git a/modules/desktop/environment.nix b/modules/desktop/environment.nix new file mode 100644 index 0000000..b3c225c --- /dev/null +++ b/modules/desktop/environment.nix @@ -0,0 +1,3 @@ +{ + environment.sessionVariables.NIXOS_OZONE_WL = "1"; +} \ No newline at end of file diff --git a/modules/desktop/flatpak.nix b/modules/desktop/flatpak.nix new file mode 100644 index 0000000..49e9206 --- /dev/null +++ b/modules/desktop/flatpak.nix @@ -0,0 +1,14 @@ +{ config, lib, ... }: +{ + services = { + flatpak = lib.mkIf config.my.desktop.flatpak.enable { + enable = true; + packages = [ + "com.github.tchx84.Flatseal" + "org.jellyfin.JellyfinDesktop" + ]; + + update.onActivation = true; + }; + }; +} diff --git a/modules/desktop/glib-schemas-fix.nix b/modules/desktop/glib-schemas-fix.nix new file mode 100644 index 0000000..e96c3a2 --- /dev/null +++ b/modules/desktop/glib-schemas-fix.nix @@ -0,0 +1,12 @@ +# Glib Schemas Fix +# https://github.com/thomX75/nixos-modules + +{ pkgs, ... }: + +{ + environment.systemPackages = with pkgs; [ gsettings-desktop-schemas ]; + + environment.variables = { + GSETTINGS_SCHEMA_DIR="${pkgs.gsettings-desktop-schemas}/share/gsettings-schemas/${pkgs.gsettings-desktop-schemas.name}/glib-2.0/schemas"; + }; +} \ No newline at end of file diff --git a/modules/desktop/hyprland.nix b/modules/desktop/hyprland.nix new file mode 100644 index 0000000..d6e281d --- /dev/null +++ b/modules/desktop/hyprland.nix @@ -0,0 +1,11 @@ +{ inputs, pkgs, ...}: +{ + programs.hyprland = { + enable = true; + # set the flake package + package = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland; + # make sure to also set the portal package, so that they are in sync + portalPackage = inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland; + withUWSM = true; + }; +} diff --git a/modules/desktop/obs-studio.nix b/modules/desktop/obs-studio.nix new file mode 100644 index 0000000..68bb6b6 --- /dev/null +++ b/modules/desktop/obs-studio.nix @@ -0,0 +1,13 @@ +{ pkgs, ... }: +{ + programs.obs-studio = { + enable = true; + enableVirtualCamera = true; + plugins = [ + pkgs.obs-studio-plugins.obs-vkcapture + pkgs.obs-studio-plugins.obs-tuna + pkgs.obs-studio-plugins.obs-pipewire-audio-capture + pkgs.obs-studio-plugins.droidcam-obs + ]; + }; +} \ No newline at end of file diff --git a/modules/desktop/packages.nix b/modules/desktop/packages.nix new file mode 100644 index 0000000..6d8f940 --- /dev/null +++ b/modules/desktop/packages.nix @@ -0,0 +1,50 @@ +{ pkgs, ...}: + +{ + environment.systemPackages = with pkgs; [ + kitty + thunderbird + bitwarden-desktop + pwvucontrol + firefox + gedit + wl-clipboard + tuigreet + brightnessctl + spotify + hyprshot + mpv + #jellyfin-media-player + gedit + nixfmt + nixd + xfce.thunar + xfce.thunar-archive-plugin + xfce.thunar-media-tags-plugin + droidcam + rustdesk + mailspring + rquickshare + btrfs-assistant + ungoogled-chromium + gparted + veracrypt + lshw + syncplay + tigervnc + solaar + logitech-udev-rules + yubioath-flutter + kdePackages.gwenview + gsettings-desktop-schemas + gnome-tweaks + appimage-run + ]; + programs.seahorse.enable = true; + programs.streamcontroller.enable = true; + programs.appimage = { + enable = true; + binfmt = true; + }; + programs.yubikey-manager.enable = true; +} diff --git a/modules/desktop/rgb.nix b/modules/desktop/rgb.nix new file mode 100644 index 0000000..bc27e47 --- /dev/null +++ b/modules/desktop/rgb.nix @@ -0,0 +1,14 @@ +{ lib, config, inputs, pkgs, ... }: +let + cfg = config.my.rgb; +in +{ + config = lib.mkIf cfg.enable { + services.hardware.openrgb = { + enable = true; + }; + environment.systemPackages = [ + inputs.artemisrgb.packages.${pkgs.stdenv.hostPlatform.system}.default + ]; + }; +} \ No newline at end of file diff --git a/modules/desktop/sddm-background/wallpaper.png b/modules/desktop/sddm-background/wallpaper.png new file mode 100644 index 0000000..54c07bc Binary files /dev/null and b/modules/desktop/sddm-background/wallpaper.png differ diff --git a/modules/desktop/sddm.nix b/modules/desktop/sddm.nix new file mode 100644 index 0000000..0733f6f --- /dev/null +++ b/modules/desktop/sddm.nix @@ -0,0 +1,30 @@ +{ pkgs, lib, username, config, ... }: +let + cfg = config.my.desktop; +in +{ + services.displayManager.sddm = { + enable = cfg.sddm.enable; + theme = "catppuccin-mocha-mauve"; + package = pkgs.kdePackages.sddm; + wayland.enable = true; + settings = { + Autologin = lib.optionalAttrs cfg.sddm.autoLogin.enable { + User = "${username}"; + Session = cfg.sddm.autoLogin.session; + }; + }; + }; + + environment.systemPackages = + lib.optionals cfg.sddm.enable [( + pkgs.catppuccin-sddm.override { + flavor = "mocha"; + accent = "mauve"; + font = "Noto Sans"; + fontSize = "9"; + background = "${./sddm-background/wallpaper.png}"; + loginBackground = true; + } + )]; +} \ No newline at end of file diff --git a/modules/desktop/xdg.nix b/modules/desktop/xdg.nix new file mode 100644 index 0000000..492b14c --- /dev/null +++ b/modules/desktop/xdg.nix @@ -0,0 +1,16 @@ +{ pkgs, inputs, ...}: + +{ + xdg = { + mime.enable = true; + menus.enable = true; + portal = { + enable = true; + extraPortals = [ + inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.xdg-desktop-portal-hyprland + pkgs.xdg-desktop-portal-gtk + ]; + configPackages = [inputs.hyprland.packages.${pkgs.stdenv.hostPlatform.system}.hyprland]; + }; + }; +} diff --git a/modules/fonts.nix b/modules/fonts.nix new file mode 100644 index 0000000..5df4e89 --- /dev/null +++ b/modules/fonts.nix @@ -0,0 +1,31 @@ +{pkgs, ...}: { + fonts = { + packages = with pkgs; [ + dejavu_fonts + fira-code + fira-code-symbols + font-awesome + hackgen-nf-font + ibm-plex + inter + jetbrains-mono + material-icons + maple-mono.NF + minecraftia + nerd-fonts.im-writing + nerd-fonts.blex-mono + noto-fonts + noto-fonts-color-emoji + noto-fonts-cjk-sans + noto-fonts-cjk-serif + noto-fonts-monochrome-emoji + powerline-fonts + roboto + roboto-mono + symbola + terminus_font + corefonts + vista-fonts + ]; + }; +} diff --git a/modules/gaming/anime-game-launchers.nix b/modules/gaming/anime-game-launchers.nix new file mode 100644 index 0000000..acd8620 --- /dev/null +++ b/modules/gaming/anime-game-launchers.nix @@ -0,0 +1,13 @@ +{ lib, config, inputs, ... }: +let + cfg = config.my.gaming; +in +{ + imports = [ + inputs.aagl.nixosModules.default + ]; + config = lib.mkIf cfg.enable { + programs.honkers-railway-launcher.enable = true; + programs.sleepy-launcher.enable = true; + }; +} \ No newline at end of file diff --git a/modules/gaming/default.nix b/modules/gaming/default.nix new file mode 100644 index 0000000..09a4da8 --- /dev/null +++ b/modules/gaming/default.nix @@ -0,0 +1,19 @@ +{ lib, ... }: +let + b = builtins; + + module_files = + b.readDir ./. |> + lib.filterAttrs (name: type: + ( (lib.strings.hasSuffix ".nix" name + && name != "default.nix" + && type == "regular" ) + || ( type == "directory" + && b.pathExists ./${name}/default.nix)) + ) |> + b.attrNames |> + b.map (f: ./${f}); +in +{ + imports = module_files; +} \ No newline at end of file diff --git a/modules/gaming/packages.nix b/modules/gaming/packages.nix new file mode 100644 index 0000000..49e897d --- /dev/null +++ b/modules/gaming/packages.nix @@ -0,0 +1,14 @@ +{ pkgs, ... }: +{ + environment.systemPackages = with pkgs; [ + heroic + vulkan-hdr-layer-kwin6 + lsfg-vk + lsfg-vk-ui + gamescope + gamescope-wsi + moonlight-qt + bs-manager + wine + ]; +} \ No newline at end of file diff --git a/modules/gaming/steam.nix b/modules/gaming/steam.nix new file mode 100644 index 0000000..3a4aba4 --- /dev/null +++ b/modules/gaming/steam.nix @@ -0,0 +1,25 @@ +{ pkgs, ... }: +{ + programs = { + steam = { + enable = true; + remotePlay.openFirewall = true; + dedicatedServer.openFirewall = false; + gamescopeSession.enable = false; + extraPackages = with pkgs; [ + steamtinkerlaunch + ]; + extraCompatPackages = with pkgs; [ + steamtinkerlaunch + ]; + }; + gamescope = { + enable = true; + capSysNice = true; + }; + }; + environment.systemPackages = with pkgs; [ + steamtinkerlaunch + protonup-qt + ]; +} diff --git a/modules/gaming/wivrn.nix b/modules/gaming/wivrn.nix new file mode 100644 index 0000000..e228f0a --- /dev/null +++ b/modules/gaming/wivrn.nix @@ -0,0 +1,21 @@ +{ pkgs, ... }: +{ + services.wivrn = { + enable = true; + openFirewall = true; + + # Write information to /etc/xdg/openxr/1/active_runtime.json, VR applications + # will automatically read this and work with WiVRn (Note: This does not currently + # apply for games run in Valve's Proton) + defaultRuntime = true; + + # Run WiVRn as a systemd service on startup + autoStart = true; + + # If you're running this with an nVidia GPU and want to use GPU Encoding (and don't otherwise have CUDA enabled system wide), you need to override the cudaSupport variable. + package = (pkgs.wivrn.override { cudaSupport = true; }); + + # You should use the default configuration (which is no configuration), as that works the best out of the box. + # However, if you need to configure something see https://github.com/WiVRn/WiVRn/blob/master/docs/configuration.md for configuration options and https://mynixos.com/nixpkgs/option/services.wivrn.config.json for an example configuration. +}; +} \ No newline at end of file diff --git a/modules/hardware.nix b/modules/hardware.nix new file mode 100644 index 0000000..a6a9209 --- /dev/null +++ b/modules/hardware.nix @@ -0,0 +1,20 @@ +{pkgs, ...}: { + hardware = { + sane = { + enable = true; + extraBackends = [pkgs.sane-airscan]; + disabledDefaultBackends = ["escl"]; + }; + logitech.wireless.enable = true; + logitech.wireless.enableGraphical = true; + graphics = { + enable = true; + enable32Bit = true; + }; + amdgpu.opencl.enable = true; + enableRedistributableFirmware = true; + keyboard.qmk.enable = true; + bluetooth.enable = true; + bluetooth.powerOnBoot = true; + }; +} diff --git a/modules/ld.nix b/modules/ld.nix new file mode 100644 index 0000000..db5fb6c --- /dev/null +++ b/modules/ld.nix @@ -0,0 +1,35 @@ +{ pkgs, ... }: +{ + programs.nix-ld.enable = true; + programs.nix-ld.libraries = with pkgs; [ + stdenv.cc.cc + glibc + xorg.libX11 + xorg.libXcursor + xorg.libXrandr + xorg.libXinerama + xorg.libXi + wayland + libGL + libdrm + alsa-lib + pulseaudio + glib + nspr.out + nss.out + dbus.lib + at-spi2-atk + cups.lib + cairo.out + gtk3.out + pango.out + libxcomposite.out + libxdamage.out + libxext.out + libxfixes.out + libgbm.out + expat.out + libxcb.out + libxkbcommon.out + ]; +} \ No newline at end of file diff --git a/modules/network.nix b/modules/network.nix new file mode 100644 index 0000000..22b8091 --- /dev/null +++ b/modules/network.nix @@ -0,0 +1,30 @@ +{ + options, + ... +}: +{ + networking = { + hostName = "LillyPC"; + networkmanager.enable = true; + timeServers = options.networking.timeServers.default ++ ["pool.ntp.org"]; + firewall = { + enable = false; + allowedTCPPorts = [ + 22 + 80 + 443 + 59010 + 59011 + 8080 + ]; + allowedUDPPorts = [ + 59010 + 59011 + ]; + }; + }; + services.tailscale = { + enable = true; + useRoutingFeatures = "client"; + }; +} diff --git a/modules/nvidia.nix b/modules/nvidia.nix new file mode 100644 index 0000000..5f4eb85 --- /dev/null +++ b/modules/nvidia.nix @@ -0,0 +1,32 @@ +{ + config, + pkgs, + lib, + ... +}: +let + cfg = config.my; +in +{ + config = lib.mkIf cfg.nvidia.enable { + services.xserver.videoDrivers = lib.optionals cfg.nvidia.enable ["nvidia"]; + hardware.nvidia = { + modesetting.enable = true; + powerManagement.enable = true; + powerManagement.finegrained = false; + open = true; + nvidiaSettings = cfg.desktop.enable; + # Optionally, you may need to select the appropriate driver version for your specific GPU. + package = config.boot.kernelPackages.nvidiaPackages.stable; + }; + hardware.nvidia-container-toolkit.enable = config.virtualisation.docker.enable; + environment.systemPackages = with pkgs; [ + nvidia_oc + nvidia-vaapi-driver + ] + ++ lib.optionals config.virtualisation.docker.enable [ + nvidia-docker + nvidia-container-toolkit + ]; + }; +} diff --git a/modules/packages.nix b/modules/packages.nix new file mode 100644 index 0000000..80cd368 --- /dev/null +++ b/modules/packages.nix @@ -0,0 +1,12 @@ +{ pkgs, ...}: + +{ + environment.systemPackages = with pkgs; [ + firefoxpwa + hyprpolkitagent + hypridle + hyprpicker + lsb-release + papirus-icon-theme + ]; +} diff --git a/modules/services.nix b/modules/services.nix new file mode 100644 index 0000000..2308335 --- /dev/null +++ b/modules/services.nix @@ -0,0 +1,56 @@ +{ + # Services to start + services = { + upower.enable = true; # noctalia shell battery + libinput.enable = true; # Input Handling + fstrim.enable = true; # SSD Optimizer + gvfs.enable = true; # For Mounting USB & More + power-profiles-daemon.enable = true; + openssh = { + enable = true; # Enable SSH + settings = { + PermitRootLogin = "no"; # Prevent root from SSH login + PasswordAuthentication = true; #Users can SSH using kb and password + KbdInteractiveAuthentication = true; + }; + ports = [22]; + }; + blueman.enable = true; # Bluetooth Support + tumbler.enable = true; # Image/video preview + gnome.gnome-keyring.enable = true; + + smartd = { + enable = true; + autodetect = true; + }; + pipewire = { + enable = true; + alsa.enable = true; + alsa.support32Bit = true; + pulse.enable = true; + jack.enable = true; + extraConfig.pipewire."92-low-latency" = { + "context.properties" = { + "default.clock.rate" = 48000; + "default.clock.quantum" = 256; + "default.clock.min-quantum" = 256; + "default.clock.max-quantum" = 256; + }; + }; + extraConfig.pipewire-pulse."92-low-latency" = { + context.modules = [ + { + name = "libpipewire-module-protocol-pulse"; + args = { + pulse.min.req = "256/48000"; + pulse.default.req = "256/48000"; + pulse.max.req = "256/48000"; + pulse.min.quantum = "256/48000"; + pulse.max.quantum = "256/48000"; + }; + } + ]; + }; + }; + }; +} diff --git a/options.nix b/options.nix new file mode 100644 index 0000000..e450266 --- /dev/null +++ b/options.nix @@ -0,0 +1,46 @@ +{ lib, ... }: +{ + options.my = { + + gaming.enable = lib.mkEnableOption "Gaming"; + + cachyosKernel.enable = lib.mkEnableOption "CachyOS Kernel"; + + nvidia = { + enable = lib.mkEnableOption "Has NVIDIA GPU"; + }; + + openlinkhub.enable = lib.mkEnableOption "Has Corsair Link Hardware"; + + rgb.enable = lib.mkEnableOption "Has RGB"; + + desktop = { + enable = lib.mkEnableOption "Is a Desktop System"; + + sddm = { + enable = lib.mkEnableOption "SDDM"; + autoLogin = { + enable = lib.mkEnableOption "SDDM AutoLogin"; + session = lib.mkOption { + type = lib.types.str; + default = "hyprland-uwsm.desktop"; + example = "hyprland-uwsm.desktop"; + description = "Name of the autologin session desktop file"; + }; + }; + }; + + hyprland = { + enable = lib.mkEnableOption "Hyprland"; + }; + + kdePlasma = { + enable = lib.mkEnableOption "Hyprland"; + }; + + flatpak = { + enable = lib.mkEnableOption "Flatpak Support"; + }; + }; + }; +} diff --git a/services/artemis-rgb/flake.nix b/services/artemis-rgb/flake.nix new file mode 100644 index 0000000..261ffc9 --- /dev/null +++ b/services/artemis-rgb/flake.nix @@ -0,0 +1,98 @@ +{ + description = "Artemis RGB (Avalonia + SkiaSharp, NixOS compatible)"; + + inputs = { + nixpkgs.url = "github:NixOS/nixpkgs/nixos-25.11"; + }; + + outputs = { nixpkgs, ... }: + let + system = "x86_64-linux"; + + pkgs = import nixpkgs { + inherit system; + config.allowUnfree = true; + }; + + artemis = pkgs.stdenvNoCC.mkDerivation rec { + pname = "artemis-rgb"; + version = "latest-master"; + + src = pkgs.fetchurl { + url = "https://updating.artemis-rgb.com/api/artifacts/latest/master/linux"; + sha256 = "sha256-YzgkzfVZbxSesrVTZTvUXWm8K2TBA6pQbiN9ErDGzeA="; + }; + + nativeBuildInputs = [ + pkgs.unzip + pkgs.makeWrapper + ]; + + buildInputs = [ + # .NET runtime deps + pkgs.icu + pkgs.zlib + pkgs.openssl + + # Skia / fonts + pkgs.fontconfig + pkgs.freetype + + # X11 (required even on Wayland for Avalonia) + pkgs.xorg.libX11 + pkgs.xorg.libXcursor + pkgs.xorg.libXrandr + pkgs.xorg.libXi + pkgs.xorg.libXinerama + pkgs.xorg.libxcb + pkgs.xorg.libICE + pkgs.xorg.libSM + + # Graphics / display + pkgs.mesa + pkgs.wayland + ]; + + unpackPhase = '' + unzip $src + ''; + + installPhase = '' + mkdir -p $out/lib/artemis + cp -r ./* $out/lib/artemis + chmod +x $out/lib/artemis/Artemis.UI.Linux + + mkdir -p $out/bin + makeWrapper $out/lib/artemis/Artemis.UI.Linux \ + $out/bin/Artemis.UI.Linux \ + --set LD_LIBRARY_PATH "${pkgs.lib.makeLibraryPath buildInputs}" + + mkdir -p $out/share/applications + cat > $out/share/applications/artemis.desktop < + lib.filterAttrs (name: type: + ( (lib.strings.hasSuffix ".nix" name + && name != "default.nix" + && type == "regular" ) + || ( type == "directory" + && b.pathExists ./${name}/default.nix)) + ) |> + b.attrNames |> + b.map (f: ./${f}); +in +{ + imports = module_files; +} \ No newline at end of file diff --git a/system/user.nix b/system/user.nix new file mode 100644 index 0000000..6b284c6 --- /dev/null +++ b/system/user.nix @@ -0,0 +1,24 @@ +{ + pkgs, + username, + prettyUsername, + ... +}: { + users.mutableUsers = true; + users.users.${username} = { + isNormalUser = true; + description = "${prettyUsername}"; + extraGroups = [ + "adbusers" + "docker" #access to docker as non-root + "libvirtd" #Virt manager/QEMU access +# "lp" + "networkmanager" + "scanner" + "wheel" #sudo access + ]; + shell = pkgs.bash; +# ignoreShellProgramCheck = true; + }; + nix.settings.allowed-users = [ "${username}" ]; +}