Update nixpkgs & add X2100
This commit is contained in:
parent
00ec288b8b
commit
f3cbc3955d
10
flake.lock
generated
10
flake.lock
generated
@ -247,17 +247,17 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_4": {
|
"nixpkgs_4": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1601171649,
|
"lastModified": 1604369895,
|
||||||
"narHash": "sha256-G3RUAi2DUq6r3ntASLS+LZC/Eamot55W1+xmBOgEh3M=",
|
"narHash": "sha256-uB/ihiWdfTjVQ9sKdtj6xeyvb41uC2J4MXiOLkwJccs=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs-channels",
|
"repo": "nixpkgs",
|
||||||
"rev": "84d74ae9c9cbed73274b8e4e00be14688ffc93fe",
|
"rev": "34ad166a830d3ac1541dcce571c52231f2f0865a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"ref": "nixos-unstable",
|
"ref": "nixos-unstable",
|
||||||
"repo": "nixpkgs-channels",
|
"repo": "nixpkgs",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
"A collection of crap, hacks and copy-paste to make my localhosts boot";
|
"A collection of crap, hacks and copy-paste to make my localhosts boot";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = github:nixos/nixpkgs-channels/nixos-unstable;
|
nixpkgs.url = github:nixos/nixpkgs/nixos-unstable;
|
||||||
# nixpkgs-mesa.url = github:nixos/nixpkgs-channels/bdac777becdbb8780c35be4f552c9d4518fe0bdb;
|
# nixpkgs-mesa.url = github:nixos/nixpkgs-channels/bdac777becdbb8780c35be4f552c9d4518fe0bdb;
|
||||||
lambda-launcher.url = github:balsoft/lambda-launcher;
|
lambda-launcher.url = github:balsoft/lambda-launcher;
|
||||||
NUR = {
|
NUR = {
|
||||||
|
31
hardware-configuration/X2100-Laptop.nix
Executable file
31
hardware-configuration/X2100-Laptop.nix
Executable file
@ -0,0 +1,31 @@
|
|||||||
|
# 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, inputs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports =
|
||||||
|
[ "${inputs.nixpkgs}/nixos/modules/installer/scan/not-detected.nix" ];
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
|
||||||
|
boot.initrd.kernelModules = [ ];
|
||||||
|
boot.kernelModules = [ "kvm-intel" ];
|
||||||
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
|
fileSystems."/" =
|
||||||
|
{ device = "/dev/nvme0n1p2";
|
||||||
|
fsType = "ext4";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/boot" =
|
||||||
|
{ device = "/dev/nvme0n1p1";
|
||||||
|
fsType = "vfat";
|
||||||
|
};
|
||||||
|
|
||||||
|
swapDevices = [ ];
|
||||||
|
|
||||||
|
console.font = lib.mkDefault "${pkgs.terminus_font}/share/consolefonts/ter-u28n.psf.gz";
|
||||||
|
|
||||||
|
nix.maxJobs = lib.mkDefault 8;
|
||||||
|
powerManagement.cpuFreqGovernor = lib.mkDefault "powersave";
|
||||||
|
}
|
@ -7,16 +7,6 @@ in {
|
|||||||
MOZ_DBUS_REMOTE = "1";
|
MOZ_DBUS_REMOTE = "1";
|
||||||
};
|
};
|
||||||
home-manager.users.balsoft = lib.mkIf (config.deviceSpecific.goodMachine) {
|
home-manager.users.balsoft = lib.mkIf (config.deviceSpecific.goodMachine) {
|
||||||
home.packages = with pkgs; [
|
|
||||||
plasma-integration
|
|
||||||
plasma-browser-integration
|
|
||||||
];
|
|
||||||
home.file.".mozilla/native-messaging-hosts".source = pkgs.symlinkJoin {
|
|
||||||
name = "native-messaging-hosts";
|
|
||||||
paths = [
|
|
||||||
"${pkgs.plasma-browser-integration}/lib/mozilla/native-messaging-hosts"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
programs.firefox = {
|
programs.firefox = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.firefox-wayland;
|
package = pkgs.firefox-wayland;
|
||||||
@ -67,7 +57,6 @@ in {
|
|||||||
close-other-windows
|
close-other-windows
|
||||||
adsum-notabs
|
adsum-notabs
|
||||||
ublock-origin
|
ublock-origin
|
||||||
plasma-integration
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -94,6 +94,19 @@ with types; {
|
|||||||
};
|
};
|
||||||
ram = 2;
|
ram = 2;
|
||||||
};
|
};
|
||||||
|
X2100-Laptop = {
|
||||||
|
cpu = {
|
||||||
|
vendor = "intel";
|
||||||
|
clock = 4800;
|
||||||
|
cores = 4;
|
||||||
|
};
|
||||||
|
drive = {
|
||||||
|
type = "ssd";
|
||||||
|
speed = 6000;
|
||||||
|
size = 256;
|
||||||
|
};
|
||||||
|
ram = 16;
|
||||||
|
};
|
||||||
NixOS-VM = {
|
NixOS-VM = {
|
||||||
cpu = {
|
cpu = {
|
||||||
vendor = "intel";
|
vendor = "intel";
|
||||||
|
@ -27,7 +27,6 @@ with import ../../../support.nix { inherit lib config; }; {
|
|||||||
pkgs.media-player-info
|
pkgs.media-player-info
|
||||||
];
|
];
|
||||||
|
|
||||||
nixpkgs.config.firefox.enablePlasmaBrowserIntegration = true;
|
|
||||||
environment.sessionVariables = {
|
environment.sessionVariables = {
|
||||||
DESKTOP_SESSION = "kde";
|
DESKTOP_SESSION = "kde";
|
||||||
QT_XFT = "true";
|
QT_XFT = "true";
|
||||||
|
@ -2,8 +2,10 @@
|
|||||||
let
|
let
|
||||||
thm = config.themes.colors;
|
thm = config.themes.colors;
|
||||||
apps = config.defaultApplications;
|
apps = config.defaultApplications;
|
||||||
lock_fork = pkgs.writeShellScript "lock_fork" "sudo /run/current-system/sw/bin/lock &";
|
lock_fork =
|
||||||
lock = pkgs.writeShellScript "lock" "swaymsg 'output * dpms off'; sudo /run/current-system/sw/bin/lock; swaymsg 'output * dpms on'";
|
pkgs.writeShellScript "lock_fork" "sudo /run/current-system/sw/bin/lock &";
|
||||||
|
lock = pkgs.writeShellScript "lock"
|
||||||
|
"swaymsg 'output * dpms off'; sudo /run/current-system/sw/bin/lock; swaymsg 'output * dpms on'";
|
||||||
in {
|
in {
|
||||||
environment.sessionVariables._JAVA_AWT_WM_NONREPARENTING = "1";
|
environment.sessionVariables._JAVA_AWT_WM_NONREPARENTING = "1";
|
||||||
|
|
||||||
@ -11,12 +13,15 @@ in {
|
|||||||
|
|
||||||
programs.sway.extraPackages = lib.mkForce (with pkgs; [ swayidle xwayland ]);
|
programs.sway.extraPackages = lib.mkForce (with pkgs; [ swayidle xwayland ]);
|
||||||
|
|
||||||
|
|
||||||
home-manager.users.balsoft.wayland.windowManager.sway = {
|
home-manager.users.balsoft.wayland.windowManager.sway = {
|
||||||
enable = true;
|
enable = true;
|
||||||
config = rec {
|
config = rec {
|
||||||
assigns = {
|
assigns = {
|
||||||
"" = [ { class = "Chromium"; } { app_id = "firefox"; } { class = "Firefox"; } ];
|
"" = [
|
||||||
|
{ class = "Chromium"; }
|
||||||
|
{ app_id = "firefox"; }
|
||||||
|
{ class = "Firefox"; }
|
||||||
|
];
|
||||||
"" = [
|
"" = [
|
||||||
{ app_id = "org.kde.trojita"; }
|
{ app_id = "org.kde.trojita"; }
|
||||||
{ title = ".* - Sylpheed.*"; }
|
{ title = ".* - Sylpheed.*"; }
|
||||||
@ -89,14 +94,14 @@ in {
|
|||||||
{ command = "${pkgs.cantata}/bin/cantata"; }
|
{ command = "${pkgs.cantata}/bin/cantata"; }
|
||||||
|
|
||||||
{
|
{
|
||||||
command = "swayidle -w before-sleep '${lock_fork}' lock '${lock_fork}' unlock 'pkill -9 swaylock'";
|
command =
|
||||||
|
"swayidle -w before-sleep '${lock_fork}' lock '${lock_fork}' unlock 'pkill -9 swaylock'";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
command = "${pkgs.xdg-desktop-portal-kde}/libexec/xdg-desktop-portal-kde";
|
command =
|
||||||
}
|
"${pkgs.xdg-desktop-portal-kde}/libexec/xdg-desktop-portal-kde";
|
||||||
{
|
|
||||||
command = "${pkgs.xdg-desktop-portal}/libexec/xdg-desktop-portal";
|
|
||||||
}
|
}
|
||||||
|
{ command = "${pkgs.xdg-desktop-portal}/libexec/xdg-desktop-portal"; }
|
||||||
];
|
];
|
||||||
|
|
||||||
keybindings = let
|
keybindings = let
|
||||||
@ -192,8 +197,10 @@ in {
|
|||||||
"XF86AudioLowerVolume" = "exec ${pkgs.pamixer}/bin/pamixer -d 2";
|
"XF86AudioLowerVolume" = "exec ${pkgs.pamixer}/bin/pamixer -d 2";
|
||||||
"XF86AudioRaiseVolume" = "exec ${pkgs.pamixer}/bin/pamixer -i 2";
|
"XF86AudioRaiseVolume" = "exec ${pkgs.pamixer}/bin/pamixer -i 2";
|
||||||
"XF86AudioMute" = "exec ${pkgs.pamixer}/bin/pamixer -t";
|
"XF86AudioMute" = "exec ${pkgs.pamixer}/bin/pamixer -t";
|
||||||
"${modifier}+XF86AudioLowerVolume" = "exec ${pkgs.pamixer}/bin/pamixer -d 1";
|
"${modifier}+XF86AudioLowerVolume" =
|
||||||
"${modifier}+XF86AudioRaiseVolume" = "exec ${pkgs.pamixer}/bin/pamixer -i 1";
|
"exec ${pkgs.pamixer}/bin/pamixer -d 1";
|
||||||
|
"${modifier}+XF86AudioRaiseVolume" =
|
||||||
|
"exec ${pkgs.pamixer}/bin/pamixer -i 1";
|
||||||
"button2" = "kill";
|
"button2" = "kill";
|
||||||
"--whole-window ${modifier}+button2" = "kill";
|
"--whole-window ${modifier}+button2" = "kill";
|
||||||
} // builtins.listToAttrs (builtins.map (x: {
|
} // builtins.listToAttrs (builtins.map (x: {
|
||||||
@ -203,8 +210,7 @@ in {
|
|||||||
name = "${modifier}+Shift+${builtins.elemAt x 0}";
|
name = "${modifier}+Shift+${builtins.elemAt x 0}";
|
||||||
value = "move container to workspace ${builtins.elemAt x 1}";
|
value = "move container to workspace ${builtins.elemAt x 1}";
|
||||||
}) workspaces));
|
}) workspaces));
|
||||||
keycodebindings = {
|
keycodebindings = { };
|
||||||
};
|
|
||||||
workspaceLayout = "tabbed";
|
workspaceLayout = "tabbed";
|
||||||
workspaceAutoBackAndForth = true;
|
workspaceAutoBackAndForth = true;
|
||||||
input = {
|
input = {
|
||||||
@ -213,20 +219,24 @@ in {
|
|||||||
natural_scroll = "enabled";
|
natural_scroll = "enabled";
|
||||||
dwt = "enabled";
|
dwt = "enabled";
|
||||||
};
|
};
|
||||||
"2:14:ETPS/2_Elantech_TrackPoint" = {
|
"2:14:ETPS/2_Elantech_TrackPoint" = { pointer_accel = "-0.7"; };
|
||||||
pointer_accel = "-0.7";
|
"2:10:TPPS/2_IBM_TrackPoint" = {
|
||||||
|
pointer_accel = "0.4";
|
||||||
|
accel_profile = "adaptive";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
output = {
|
output = {
|
||||||
"*".bg = "${thm.bg} solid_color";
|
"*".bg = "${thm.bg} solid_color";
|
||||||
} // lib.optionalAttrs (config.device == "AMD-Workstation") {
|
} // lib.optionalAttrs (config.device == "AMD-Workstation") {
|
||||||
DP-1.position = "0 400";
|
DP-1.position = "0 400";
|
||||||
HDMI-A-1 = { transform = "90"; position = "2560 0"; };
|
HDMI-A-1 = {
|
||||||
|
transform = "90";
|
||||||
|
position = "2560 0";
|
||||||
|
};
|
||||||
|
"Unknown 0x0000 0x00000000".scale = "2";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
wrapperFeatures = {
|
wrapperFeatures = { gtk = true; };
|
||||||
gtk = true;
|
|
||||||
};
|
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
default_border pixel 1
|
default_border pixel 1
|
||||||
mouse_warping container
|
mouse_warping container
|
||||||
@ -235,4 +245,3 @@ in {
|
|||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user