diff --git a/modules/aliases.nix b/modules/aliases.nix index 2b254cd..eaf9076 100644 --- a/modules/aliases.nix +++ b/modules/aliases.nix @@ -20,8 +20,5 @@ "nix:edit:aliases" = "sudo nano ~/Developer/lavitz/modules/aliases.nix"; "nix:conf:push" = "sudo rm -rf /etc/nixos/configuration.nix && sudo cp ~/Developer/lavitz/configuration.nix /etc/nixos/configuration.nix && sudo rm -rf /etc/nixos/modules && sudo cp -r ~/Developer/lavitz/modules /etc/nixos/ && cd ~/Developer/lavitz && git add -A && git commit -m \"$(date -u +%s)\" && git push"; "nix:conf:pull" = "cd ~/Developer/lavitz && git pull && sudo rm -rf /etc/nixos/configuration.nix && sudo cp ~/Developer/lavitz/configuration.nix /etc/nixos/configuration.nix && sudo rm -rf /etc/nixos/modules && sudo cp -r ~/Developer/lavitz/modules /etc/nixos/"; - - # General Utils - "audio:reset" = "pactl set-default-source alsa_input.usb-Elgato_Systems_Elgato_Wave_3_BS31K1A05440-00.mono-fallback"; }; -} +} diff --git a/modules/audio.nix b/modules/audio.nix index 44f64b3..80cc673 100644 --- a/modules/audio.nix +++ b/modules/audio.nix @@ -1,7 +1,6 @@ { config, pkgs, ... }: { - # Pulse Audio security.rtkit.enable = true; # Pipewire @@ -11,4 +10,4 @@ alsa.support32Bit = true; pulse.enable = true; }; -} \ No newline at end of file +} diff --git a/modules/boot.nix b/modules/boot.nix index 953afe4..d54082c 100644 --- a/modules/boot.nix +++ b/modules/boot.nix @@ -5,7 +5,7 @@ boot.loader.systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = true; - # Use latest kernel + # Kernel boot.kernelPackages = pkgs.linuxPackages_latest; nix.settings.experimental-features = [ "nix-command" "flakes" ]; @@ -17,4 +17,4 @@ ]; boot.kernelParams = [ "preempt=full" ]; -} +} diff --git a/modules/desktop.nix b/modules/desktop.nix index 1a09b0b..494b7c8 100644 --- a/modules/desktop.nix +++ b/modules/desktop.nix @@ -1,19 +1,19 @@ { config, pkgs, ... }: { - # Enable the X11 windowing system + # Enable X11 services.xserver.enable = true; - # Enable the GNOME Desktop Environment + # Enable GNOME services.xserver.displayManager.gdm.enable = true; services.xserver.desktopManager.gnome.enable = true; - # Configure keymap in X11 + # Configure XKB services.xserver.xkb = { layout = "us"; variant = ""; }; - # Enable CUPS to print documents + # Enable CUPS for printing services.printing.enable = true; -} \ No newline at end of file +} diff --git a/modules/hardware.nix b/modules/hardware.nix index 6f4936d..aaaf5bc 100644 --- a/modules/hardware.nix +++ b/modules/hardware.nix @@ -5,8 +5,8 @@ hardware.graphics = { enable = true; }; - - # Load nvidia driver for Xorg and Wayland + + # Load nvidia driver for X and Wayland services.xserver.videoDrivers = ["nvidia"]; hardware.nvidia = { @@ -17,7 +17,4 @@ open = false; nvidiaSettings = true; }; - - # # Enable CUDA OS-wide - # nixpkgs.config.cudaSupport = true; -} +} diff --git a/modules/networking.nix b/modules/networking.nix index 87b16df..b2a553f 100644 --- a/modules/networking.nix +++ b/modules/networking.nix @@ -9,4 +9,4 @@ # Open ports in the firewall. # networking.firewall.allowedTCPPorts = [ ... ]; # networking.firewall.allowedUDPPorts = [ ... ]; -} \ No newline at end of file +} diff --git a/modules/packages.nix b/modules/packages.nix index 51ccc3b..e713ab2 100644 --- a/modules/packages.nix +++ b/modules/packages.nix @@ -1,57 +1,90 @@ { config, pkgs, ... }: { - # Allow unfree packages from the stable channel + # Enable unfree globally nixpkgs.config.allowUnfree = true; - environment.systemPackages = with pkgs; [ - # Browsers and comms - ungoogled-chromium - discord - signal-desktop-bin - - # Development tools - git - go - cargo - rustc - rust-analyzer - rustfmt - nodejs_24 - python3Full - openssh - nodePackages."pnpm" - openssl - ffmpeg - vscodium - usbutils - qmk-udev-rules - qmk - - # Desktop applications - bitwarden-desktop - vlc - streamrip - supersonic - nextcloud-client - zotero - prismlauncher - lrcget - slack - impression - ardour - krita - inkscape - streamcontroller - easyeffects - - # Gaming - luanti - duckstation - dolphin-emu - ryubing - - # GNOME extensions - gnomeExtensions.appindicator + # Mount nixos-unstable under pkgs.beta + nixpkgs.overlays = [ + (final: prev: + let + beta = import + (builtins.fetchTarball + "https://github.com/NixOS/nixpkgs/archive/nixos-unstable.tar.gz") + { + system = final.system; + config = final.config; + }; + in { + beta = beta; + }) ]; -} \ No newline at end of file + + # Default browser settings + xdg = { + mime.enable = true; + mime.defaultApplications = { + "text/html" = [ "ungoogled-chromium.desktop" ]; + "application/xhtml+xml" = [ "ungoogled-chromium.desktop" ]; + "x-scheme-handler/http" = [ "ungoogled-chromium.desktop" ]; + "x-scheme-handler/https" = [ "ungoogled-chromium.desktop" ]; + "x-scheme-handler/ftp" = [ "ungoogled-chromium.desktop" ]; + "application/x-www-browser" = [ "ungoogled-chromium.desktop" ]; + }; + }; + + environment.variables.BROWSER = "chromium"; + + environment.systemPackages = + with pkgs; [ + # Browsers and comms + ungoogled-chromium + discord + signal-desktop-bin + + # Development tools + git + go + cargo + rustc + rust-analyzer + rustfmt + nodejs_24 + python3Full + openssh + nodePackages."pnpm" + openssl + ffmpeg + beta.zed-editor + usbutils + qmk-udev-rules + qmk + + # Desktop applications + bitwarden-desktop + thunderbird + vlc + streamrip + supersonic + nextcloud-client + zotero + prismlauncher + lrcget + slack + impression + ardour + krita + inkscape + streamcontroller + easyeffects + + # Gaming + luanti + duckstation + dolphin-emu + ryubing + + # GNOME extensions + gnomeExtensions.appindicator + ]; +} diff --git a/modules/services.nix b/modules/services.nix index f7dc828..6c4da76 100644 --- a/modules/services.nix +++ b/modules/services.nix @@ -4,7 +4,7 @@ # Enable the OpenSSH daemon services.openssh.enable = true; - # Sleep configuration optimized for NVIDIA + # Sleep config for NVIDIA systemd.sleep.extraConfig = '' AllowSuspend=yes AllowHibernation=no @@ -12,9 +12,6 @@ AllowSuspendThenHibernate=no ''; - # Docker - virtualisation.docker.enable = true; - # Fwupd services.fwupd.enable = true; @@ -25,4 +22,4 @@ ACTION=="add", SUBSYSTEM=="usb", ATTRS{idVendor}=="0b05", MODE="0660", GROUP="plugdev" ACTION=="add", SUBSYSTEM=="hidraw", ATTRS{idVendor}=="0b05", MODE="0660", GROUP="plugdev" ''; -} +} diff --git a/modules/users.nix b/modules/users.nix index 7c6533e..4fc0e19 100644 --- a/modules/users.nix +++ b/modules/users.nix @@ -11,8 +11,5 @@ isNormalUser = true; description = "Atridad"; extraGroups = [ "networkmanager" "wheel" "docker" "plugdev" ]; - packages = with pkgs; [ - thunderbird - ]; }; -} +}