mirror of
https://github.com/EdenQwQ/nixos.git
synced 2026-04-10 19:05:13 +08:00
fix screen flickering and keyboard not working
This commit is contained in:
parent
658b24fc7e
commit
9c2386d19e
7 changed files with 74 additions and 51 deletions
|
|
@ -393,7 +393,7 @@ def expand_all_hex(text: str) -> str:
|
|||
|
||||
return re.sub(
|
||||
r"((?<!&)#[A-Fa-f0-9]{3})\b",
|
||||
lambda match: ("#" + "".join([c * 2 for c in match.group(1)[1:]])),
|
||||
lambda match: "#" + "".join([c * 2 for c in match.group(1)[1:]]),
|
||||
text,
|
||||
)
|
||||
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ let
|
|||
includes ? [ ],
|
||||
ignores ? [ ],
|
||||
modes ? [ ],
|
||||
extraConfig ? '''',
|
||||
extraConfig ? "",
|
||||
}:
|
||||
(
|
||||
(map (file: "include ${file}") includes)
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@
|
|||
in
|
||||
{
|
||||
nixos.expr = # nix
|
||||
''${flake}.nixosConfigurations.${host}.options'';
|
||||
"${flake}.nixosConfigurations.${host}.options";
|
||||
home_manager.expr = # nix
|
||||
''${flake}.homeConfigurations."${user}@${host}".options'';
|
||||
};
|
||||
|
|
|
|||
|
|
@ -383,8 +383,8 @@ in
|
|||
#tray > .needs-attention {
|
||||
-gtk-icon-effect: highlight;
|
||||
}
|
||||
|
||||
'';
|
||||
|
||||
'';
|
||||
".config/mango/waybar/animation.css".text =
|
||||
# css
|
||||
''
|
||||
|
|
|
|||
|
|
@ -1,47 +1,63 @@
|
|||
# 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, ... }:
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
modulesPath,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ (modulesPath + "/hardware/cpu/intel-npu.nix")
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
imports = [
|
||||
(modulesPath + "/hardware/cpu/intel-npu.nix")
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "usbhid" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"thunderbolt"
|
||||
"nvme"
|
||||
"usb_storage"
|
||||
"usbhid"
|
||||
"sd_mod"
|
||||
];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/f6ac48f0-6517-4c80-af9e-f81178d04f94";
|
||||
fsType = "btrfs";
|
||||
};
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/f6ac48f0-6517-4c80-af9e-f81178d04f94";
|
||||
fsType = "btrfs";
|
||||
};
|
||||
|
||||
fileSystems."/nix" =
|
||||
{ device = "/dev/disk/by-uuid/f6ac48f0-6517-4c80-af9e-f81178d04f94";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=nix" ];
|
||||
};
|
||||
fileSystems."/nix" = {
|
||||
device = "/dev/disk/by-uuid/f6ac48f0-6517-4c80-af9e-f81178d04f94";
|
||||
fsType = "btrfs";
|
||||
options = [ "subvol=nix" ];
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/D519-CFA4";
|
||||
fsType = "vfat";
|
||||
options = [ "fmask=0077" "dmask=0077" ];
|
||||
};
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-uuid/D519-CFA4";
|
||||
fsType = "vfat";
|
||||
options = [
|
||||
"fmask=0077"
|
||||
"dmask=0077"
|
||||
];
|
||||
};
|
||||
|
||||
fileSystems."/home" =
|
||||
{ device = "/dev/disk/by-uuid/4360a1b0-918a-41d7-9bba-31da7e5974ff";
|
||||
fsType = "btrfs";
|
||||
};
|
||||
fileSystems."/home" = {
|
||||
device = "/dev/disk/by-uuid/4360a1b0-918a-41d7-9bba-31da7e5974ff";
|
||||
fsType = "btrfs";
|
||||
};
|
||||
|
||||
swapDevices = [
|
||||
{
|
||||
device = "/var/lib/swapfile";
|
||||
size = 16 * 1024;
|
||||
}
|
||||
];
|
||||
];
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.npu.enable = true;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,14 @@
|
|||
{ host, ... }:
|
||||
{ host, pkgs, ... }:
|
||||
{
|
||||
imports = [ ./hardware-configuration.nix ];
|
||||
system.stateVersion = "26.05";
|
||||
networking.hostName = host;
|
||||
boot.kernelParams = [
|
||||
"i8042.reset"
|
||||
"i8042.nomux"
|
||||
"i8042.nopnp"
|
||||
"i8042.dumbkbd"
|
||||
"xe.force_probe=*"
|
||||
"xe.enable_psr=0"
|
||||
];
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,26 +9,25 @@ let
|
|||
cfg = self.homeConfigurations."${user}@${host}".config;
|
||||
in
|
||||
{
|
||||
stylix =
|
||||
{
|
||||
enable = true;
|
||||
autoEnable = false;
|
||||
targets = {
|
||||
console.enable = true;
|
||||
gnome.enable = true;
|
||||
grub.enable = true;
|
||||
plymouth.enable = true;
|
||||
};
|
||||
}
|
||||
// (
|
||||
if builtins.hasAttr "base16Scheme" cfg.stylix then
|
||||
{ base16Scheme = lib.mkDefault cfg.stylix.base16Scheme; }
|
||||
else
|
||||
{ }
|
||||
)
|
||||
// (
|
||||
if builtins.hasAttr "image" cfg.stylix then { image = lib.mkDefault cfg.stylix.image; } else { }
|
||||
);
|
||||
stylix = {
|
||||
enable = true;
|
||||
autoEnable = false;
|
||||
targets = {
|
||||
console.enable = true;
|
||||
gnome.enable = true;
|
||||
grub.enable = true;
|
||||
plymouth.enable = true;
|
||||
};
|
||||
}
|
||||
// (
|
||||
if builtins.hasAttr "base16Scheme" cfg.stylix then
|
||||
{ base16Scheme = lib.mkDefault cfg.stylix.base16Scheme; }
|
||||
else
|
||||
{ }
|
||||
)
|
||||
// (
|
||||
if builtins.hasAttr "image" cfg.stylix then { image = lib.mkDefault cfg.stylix.image; } else { }
|
||||
);
|
||||
specialisation = builtins.mapAttrs (name: value: {
|
||||
configuration = {
|
||||
stylix =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue