mirror of
https://github.com/caperren/nixos-configs.git
synced 2025-11-09 20:21:14 +00:00
Recent updates
This commit is contained in:
8
.idea/.nixos-configs.iml
generated
Normal file
8
.idea/.nixos-configs.iml
generated
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<module type="PYTHON_MODULE" version="4">
|
||||||
|
<component name="NewModuleRootManager">
|
||||||
|
<content url="file://$MODULE_DIR$" />
|
||||||
|
<orderEntry type="inheritedJdk" />
|
||||||
|
<orderEntry type="sourceFolder" forTests="false" />
|
||||||
|
</component>
|
||||||
|
</module>
|
||||||
12
flake.lock
generated
12
flake.lock
generated
@@ -7,11 +7,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1727383923,
|
"lastModified": 1733317578,
|
||||||
"narHash": "sha256-4/vacp3CwdGoPf8U4e/N8OsGYtO09WTcQK5FqYfJbKs=",
|
"narHash": "sha256-anN/LcP5IuqEARvhPETg1vnbyG3IQ0wdvSAYEJfIQzA=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "ffe2d07e771580a005e675108212597e5b367d2d",
|
"rev": "ad48eb25cd0b00ce730da00fa1f8e6e6c27b397d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -22,11 +22,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1727348695,
|
"lastModified": 1733212471,
|
||||||
"narHash": "sha256-J+PeFKSDV+pHL7ukkfpVzCOO7mBSrrpJ3svwBFABbhI=",
|
"narHash": "sha256-M1+uCoV5igihRfcUKrr1riygbe73/dzNnzPsmaLCmpo=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "1925c603f17fc89f4c8f6bf6f631a802ad85d784",
|
"rev": "55d15ad12a74eb7d4646254e13638ad0c4128776",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|||||||
@@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
|
#nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
@@ -11,6 +12,7 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
outputs =
|
outputs =
|
||||||
|
# { self, nixpkgs, nixos-hardware, ... }@inputs:
|
||||||
{ self, nixpkgs, ... }@inputs:
|
{ self, nixpkgs, ... }@inputs:
|
||||||
{
|
{
|
||||||
nixosConfigurations.default = nixpkgs.lib.nixosSystem {
|
nixosConfigurations.default = nixpkgs.lib.nixosSystem {
|
||||||
@@ -21,6 +23,7 @@
|
|||||||
./hosts/cap-slim7/configuration.nix
|
./hosts/cap-slim7/configuration.nix
|
||||||
./modules/nixos/hyprland-amd.nix
|
./modules/nixos/hyprland-amd.nix
|
||||||
inputs.home-manager.nixosModules.default
|
inputs.home-manager.nixosModules.default
|
||||||
|
# nixos-hardware.nixosModules.lenovo-legion-16arha7
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -10,10 +10,13 @@
|
|||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
#boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||||
|
|
||||||
# Bootloader.
|
# Bootloader.
|
||||||
boot.loader.systemd-boot.enable = true;
|
boot.loader.systemd-boot.enable = true;
|
||||||
boot.loader.efi.canTouchEfiVariables = true;
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
|
|
||||||
|
|
||||||
networking.hostName = "cap-slim7"; # Define your hostname. #-#
|
networking.hostName = "cap-slim7"; # Define your hostname. #-#
|
||||||
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
||||||
|
|
||||||
@@ -21,6 +24,16 @@
|
|||||||
# networking.proxy.default = "http://user:password@proxy:port/";
|
# networking.proxy.default = "http://user:password@proxy:port/";
|
||||||
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
|
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
|
||||||
|
|
||||||
|
security.polkit.extraConfig = ''
|
||||||
|
polkit.addRule(function(action, subject) {
|
||||||
|
if ((action.id == "org.freedesktop.login1.reboot" ||
|
||||||
|
action.id == "org.freedesktop.login1.poweroff") &&
|
||||||
|
subject.isInGroup("powerusers")) {
|
||||||
|
return polkit.Result.YES;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
'';
|
||||||
|
|
||||||
# Enable networking
|
# Enable networking
|
||||||
networking.networkmanager.enable = true;
|
networking.networkmanager.enable = true;
|
||||||
|
|
||||||
@@ -32,6 +45,8 @@
|
|||||||
|
|
||||||
# Set your time zone.
|
# Set your time zone.
|
||||||
time.timeZone = "America/Los_Angeles";
|
time.timeZone = "America/Los_Angeles";
|
||||||
|
#time.timeZone = "Europe/Oslo";
|
||||||
|
# services.tzupdate.enable = true;
|
||||||
|
|
||||||
# Select internationalisation properties.
|
# Select internationalisation properties.
|
||||||
i18n.defaultLocale = "en_US.UTF-8";
|
i18n.defaultLocale = "en_US.UTF-8";
|
||||||
@@ -142,11 +157,11 @@
|
|||||||
rofi-bluetooth
|
rofi-bluetooth
|
||||||
wl-clipboard
|
wl-clipboard
|
||||||
networkmanager
|
networkmanager
|
||||||
alsaUtils
|
alsa-utils
|
||||||
nixfmt-rfc-style
|
nixfmt-rfc-style
|
||||||
mako
|
mako
|
||||||
podman
|
podman
|
||||||
kicad
|
# kicad
|
||||||
obsidian
|
obsidian
|
||||||
speedcrunch
|
speedcrunch
|
||||||
deadbeef
|
deadbeef
|
||||||
@@ -162,8 +177,65 @@
|
|||||||
stm32cubemx
|
stm32cubemx
|
||||||
stm32flash
|
stm32flash
|
||||||
easyeffects
|
easyeffects
|
||||||
|
brightnessctl
|
||||||
|
# power-profiles-daemon
|
||||||
|
librewolf
|
||||||
|
# lenovo-legion
|
||||||
|
powertop
|
||||||
|
wlogout
|
||||||
|
ncdu
|
||||||
|
flameshot
|
||||||
|
via
|
||||||
|
# teensyduino
|
||||||
|
teensy-udev-rules
|
||||||
|
transmission_4-qt
|
||||||
|
glmark2
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# services.automatic-timezoned.enable = true;
|
||||||
|
|
||||||
|
programs.bash.shellAliases = {
|
||||||
|
nixrebuild = "cd /etc/nixos && sudo nixos-rebuild switch --flake .#default";
|
||||||
|
nixupdate = "cd /etc/nixos && sudo nix flake update && sudo nixos-rebuild switch --flake .#default";
|
||||||
|
nixedit = "sudo nano /etc/nixos/hosts/cap-slim7/configuration.nix";
|
||||||
|
|
||||||
|
conservebatt = "sudo bash -c 'echo 1 > /sys/bus/platform/drivers/ideapad_acpi/VPC2004*/conservation_mode && cat /sys/bus/platform/drivers/ideapad_acpi/VPC2004*/conservation_mode'";
|
||||||
|
noconservebatt = "sudo bash -c 'echo 0 > /sys/bus/platform/drivers/ideapad_acpi/VPC2004*/conservation_mode && cat /sys/bus/platform/drivers/ideapad_acpi/VPC2004*/conservation_mode'";
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.appimage = {
|
||||||
|
enable = true;
|
||||||
|
binfmt = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# services.power-profiles-daemon.enable = true;
|
||||||
|
|
||||||
|
services.tlp = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
CPU_SCALING_GOVERNOR_ON_AC = "performance";
|
||||||
|
CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
|
||||||
|
CPU_MIN_PERF_ON_AC = 0;
|
||||||
|
CPU_MAX_PERF_ON_AC = 100;
|
||||||
|
# CPU_MAX_PERF_ON_AC = 35;
|
||||||
|
|
||||||
|
# CPU_SCALING_GOVERNOR_ON_BAT = "performance";
|
||||||
|
# CPU_ENERGY_PERF_POLICY_ON_BAT = "performance";
|
||||||
|
|
||||||
|
CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
|
||||||
|
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
|
||||||
|
CPU_MIN_PERF_ON_BAT = 0;
|
||||||
|
CPU_MAX_PERF_ON_BAT = 35;
|
||||||
|
# CPU_MAX_PERF_ON_BAT = 100;
|
||||||
|
|
||||||
|
#Optional helps save long term battery health
|
||||||
|
START_CHARGE_THRESH_BAT0 = 1; # On non-thinkpad lenovo, this sets conservation mode to 0
|
||||||
|
STOP_CHARGE_THRESH_BAT0 = 1; # ..., but to 1
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
hardware.keyboard.qmk.enable = true;
|
||||||
|
services.udev.packages = [ pkgs.via ];
|
||||||
services.udev.extraRules = ''
|
services.udev.extraRules = ''
|
||||||
# ST-LINK V2
|
# ST-LINK V2
|
||||||
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3748", MODE="600", TAG+="uaccess", SYMLINK+="stlinkv2_%n"
|
SUBSYSTEMS=="usb", ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3748", MODE="600", TAG+="uaccess", SYMLINK+="stlinkv2_%n"
|
||||||
@@ -199,7 +271,8 @@
|
|||||||
dina-font
|
dina-font
|
||||||
proggyfonts
|
proggyfonts
|
||||||
font-awesome
|
font-awesome
|
||||||
nerdfonts
|
nerd-fonts.symbols-only
|
||||||
|
nerd-fonts.jetbrains-mono
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.thunar.enable = true;
|
programs.thunar.enable = true;
|
||||||
|
|||||||
@@ -9,7 +9,7 @@
|
|||||||
];
|
];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "usbhid" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
|
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "usbhid" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
|
||||||
boot.initrd.kernelModules = [ ];
|
boot.initrd.kernelModules = [ "amdgpu" ];
|
||||||
boot.kernelModules = [ "kvm-amd" ];
|
boot.kernelModules = [ "kvm-amd" ];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
|||||||
@@ -33,10 +33,10 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
services.displayManager.autoLogin = {
|
# services.displayManager.autoLogin = {
|
||||||
enable = true;
|
# enable = true;
|
||||||
user = "caperren";
|
# user = "caperren";
|
||||||
};
|
# };
|
||||||
|
|
||||||
hardware.graphics = {
|
hardware.graphics = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|||||||
Reference in New Issue
Block a user