Merge desktop and laptop changes
This commit is contained in:
commit
a79d9a678d
9 changed files with 119 additions and 26 deletions
|
|
@ -5,12 +5,12 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
let
|
||||
systemType = "laptop";
|
||||
#systemType = "desktop";
|
||||
#systemType = "laptop";
|
||||
systemType = "desktop";
|
||||
in {
|
||||
nix.package = pkgs.nixUnstable;
|
||||
imports =
|
||||
[
|
||||
[
|
||||
# Hardware Specific Configuration
|
||||
./${systemType}.nix
|
||||
|
||||
|
|
@ -23,10 +23,11 @@ in {
|
|||
|
||||
./modules/audio/pipewire
|
||||
|
||||
./modules/shell/fish # This enables fish as the default shell
|
||||
#./modules/shell/fish
|
||||
./modules/shell/xonsh
|
||||
./modules/network/browsers/librewolf
|
||||
./modules/network/syncthing
|
||||
|
||||
|
||||
./modules/login/greetd
|
||||
];
|
||||
|
||||
|
|
|
|||
|
|
@ -5,6 +5,6 @@
|
|||
imports = [
|
||||
./hardware/desktop.nix
|
||||
|
||||
# ./modules/graphics/nvidia
|
||||
./modules/graphics/nvidia
|
||||
];
|
||||
}
|
||||
|
|
|
|||
55
flake.lock
generated
55
flake.lock
generated
|
|
@ -9,11 +9,11 @@
|
|||
"xdph": "xdph"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1699808562,
|
||||
"narHash": "sha256-wTU1ivhWAAGWO6Fzx4RYFruW8HrIh5X7fjy5NJPaqOc=",
|
||||
"lastModified": 1708215223,
|
||||
"narHash": "sha256-5z+NPNoiWKoaz3M4LZJ2fP+N7Vl9XGwr4QAV8rh4l4o=",
|
||||
"owner": "hyprwm",
|
||||
"repo": "Hyprland",
|
||||
"rev": "0ba2e6870478bcf1af1b6508677b46a3484fb21f",
|
||||
"rev": "683a4b07c514fa3c13cdf09e475283a69fcc7653",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -47,13 +47,35 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"hyprlang": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"hyprland",
|
||||
"xdph",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1704287638,
|
||||
"narHash": "sha256-TuRXJGwtK440AXQNl5eiqmQqY4LZ/9+z/R7xC0ie3iA=",
|
||||
"owner": "hyprwm",
|
||||
"repo": "hyprlang",
|
||||
"rev": "6624f2bb66d4d27975766e81f77174adbe58ec97",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hyprwm",
|
||||
"repo": "hyprlang",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1698134075,
|
||||
"narHash": "sha256-foCD+nuKzfh49bIoiCBur4+Fx1nozo+4C/6k8BYk4sg=",
|
||||
"lastModified": 1707546158,
|
||||
"narHash": "sha256-nYYJTpzfPMDxI8mzhQsYjIUX+grorqjKEU9Np6Xwy/0=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "8efd5d1e283604f75a808a20e6cde0ef313d07d4",
|
||||
"rev": "d934204a0f8d9198e1e4515dd6fec76a139c87f0",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -65,11 +87,11 @@
|
|||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1699825797,
|
||||
"narHash": "sha256-W2m42mVt4/O6CJFbECPfLApmi8bO+qscbmSeEKrSHEg=",
|
||||
"lastModified": 1701902328,
|
||||
"narHash": "sha256-3tiiSEgQRPps0aV40belvLk1k4Max7oRh/+hZGLtfGc=",
|
||||
"owner": "langedev",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "a69768a1c385042d46ff57396c49d26df5ac035c",
|
||||
"rev": "162f092c27afe0949253753f088c2babfba5b902",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
@ -104,18 +126,18 @@
|
|||
"flake": false,
|
||||
"locked": {
|
||||
"host": "gitlab.freedesktop.org",
|
||||
"lastModified": 1699292815,
|
||||
"narHash": "sha256-HXu98PyBMKEWLqiTb8viuLDznud/SdkdJsx5A5CWx7I=",
|
||||
"lastModified": 1706359063,
|
||||
"narHash": "sha256-5HUTG0p+nCJv3cn73AmFHRZdfRV5AD5N43g8xAePSKM=",
|
||||
"owner": "wlroots",
|
||||
"repo": "wlroots",
|
||||
"rev": "5de9e1a99d6642c2d09d589aa37ff0a8945dcee1",
|
||||
"rev": "00b869c1a96f300a8f25da95d624524895e0ddf2",
|
||||
"type": "gitlab"
|
||||
},
|
||||
"original": {
|
||||
"host": "gitlab.freedesktop.org",
|
||||
"owner": "wlroots",
|
||||
"repo": "wlroots",
|
||||
"rev": "5de9e1a99d6642c2d09d589aa37ff0a8945dcee1",
|
||||
"rev": "00b869c1a96f300a8f25da95d624524895e0ddf2",
|
||||
"type": "gitlab"
|
||||
}
|
||||
},
|
||||
|
|
@ -125,6 +147,7 @@
|
|||
"hyprland",
|
||||
"hyprland-protocols"
|
||||
],
|
||||
"hyprlang": "hyprlang",
|
||||
"nixpkgs": [
|
||||
"hyprland",
|
||||
"nixpkgs"
|
||||
|
|
@ -135,11 +158,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1697981233,
|
||||
"narHash": "sha256-y8q4XUwx+gVK7i2eLjfR32lVo7TYvEslyzrmzYEaPZU=",
|
||||
"lastModified": 1706521509,
|
||||
"narHash": "sha256-AInZ50acOJ3wzUwGzNr1TmxGTMx+8j6oSTzz4E7Vbp8=",
|
||||
"owner": "hyprwm",
|
||||
"repo": "xdg-desktop-portal-hyprland",
|
||||
"rev": "22e7a65ff9633e1dedfa5317fdffc49f68de2ff2",
|
||||
"rev": "c06fd88b3da492b8f9067be021b9184f7012b5a8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
};
|
||||
|
||||
outputs = { nixpkgs, hyprland, ... }: {
|
||||
nixosConfigurations.jibril = nixpkgs.lib.nixosSystem {
|
||||
nixosConfigurations.onizuka = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
./configuration.nix
|
||||
|
|
|
|||
39
hardware/desktop.nix
Normal file
39
hardware/desktop.nix
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
# 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, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "sd_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/f3afdc38-7550-4113-9f87-10def35845e2";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/6D40-7FAB";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices =
|
||||
[ { device = "/dev/disk/by-uuid/743a10e1-a064-41e3-a0ae-59ca54cff1b1"; }
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp5s0.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.amd.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
||||
|
|
@ -5,6 +5,7 @@
|
|||
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
wireplumber.enable = true;
|
||||
alsa.enable = false;
|
||||
alsa.support32Bit = false;
|
||||
pulse.enable = true;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,21 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
services.xserver.videoDrivers = [ "nvidia" ];
|
||||
hardware.opengl.enable = true;
|
||||
hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||
# Enable OpenGL
|
||||
hardware.opengl = {
|
||||
enable = true;
|
||||
driSupport = true;
|
||||
driSupport32Bit = true;
|
||||
};
|
||||
|
||||
services.xserver.videoDrivers = ["nvidia"];
|
||||
|
||||
hardware.nvidia = {
|
||||
modesetting.enable = true;
|
||||
package = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
nvidia-vaapi-driver
|
||||
];
|
||||
}
|
||||
|
|
|
|||
9
modules/shell/xonsh/default.nix
Normal file
9
modules/shell/xonsh/default.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
programs.xonsh.enable = true;
|
||||
|
||||
users.defaultUserShell = pkgs.xonsh;
|
||||
|
||||
environment.shells = with pkgs; [ xonsh ];
|
||||
}
|
||||
|
|
@ -2,7 +2,9 @@
|
|||
|
||||
{
|
||||
# Use the systemd-boot EFI boot loader.
|
||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.timeout = 1;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
|
||||
time.timeZone = "America/Los_Angeles";
|
||||
|
|
@ -18,12 +20,16 @@
|
|||
];
|
||||
|
||||
# XDG Compliance
|
||||
xdg.portal.config.common.default = "*";
|
||||
environment.sessionVariables = rec {
|
||||
XDG_CONFIG_HOME = "\${HOME}/.config";
|
||||
XDG_CACHE_HOME = "\${HOME}/.cache";
|
||||
XDG_STATE_HOME = "\${HOME}/.local/state";
|
||||
XDG_DATA_HOME = "\${HOME}/.local/share";
|
||||
XDG_BIN_HOME = "\${HOME}/.local/bin";
|
||||
PATH = [
|
||||
"\${HOME}/prog/scripts"
|
||||
];
|
||||
};
|
||||
|
||||
users.groups = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue