Compare commits
16 commits
main
...
nixgl-inte
Author | SHA1 | Date | |
---|---|---|---|
03f2102630 | |||
f12c757732 | |||
13b1b72ab3 | |||
9e4fbf1216 | |||
58b256850c | |||
7590541576 | |||
fbd0aa4f76 | |||
ea62c7207e | |||
7d4f0b3eb6 | |||
65fd07bbec | |||
bfd8d8193d | |||
8552070665 | |||
28ea3fd3e8 | |||
cb47a9aeda | |||
a26f773f01 | |||
c6f08ef074 |
88 changed files with 1218 additions and 1941 deletions
76
flake.lock
generated
76
flake.lock
generated
|
@ -22,15 +22,12 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"flake-utils": {
|
"flake-utils": {
|
||||||
"inputs": {
|
|
||||||
"systems": "systems"
|
|
||||||
},
|
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1731533236,
|
"lastModified": 1659877975,
|
||||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
"narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
"rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -46,11 +43,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1758810399,
|
"lastModified": 1748955489,
|
||||||
"narHash": "sha256-bpWoE1tiFX5T1tr5EudkpW9Kk02XR+6olkoSkf3nHZU=",
|
"narHash": "sha256-OmZXyW2g5qIuo5Te74McwR0TwauCO2sF3/SjGDVuxyg=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "39d26c16866260eee6d0487fe9c102ba1c1bf7b2",
|
"rev": "bb846c031be68a96466b683be32704ef6e07b159",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -64,10 +61,10 @@
|
||||||
"nixpkgs": "nixpkgs"
|
"nixpkgs": "nixpkgs"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1759789371,
|
"lastModified": 1755552883,
|
||||||
"narHash": "sha256-diiyS8Bj/M9UdmiIEos0QBHIIpj/AdO9+dsb2Oc9qws=",
|
"narHash": "sha256-wdVtGyN8JkpByIiNwSevZMBy02vWwCPNaD/caCQJ6aM=",
|
||||||
"ref": "main",
|
"ref": "main",
|
||||||
"rev": "e6e9d0c0a7cc152ec48ce07cccf56f57a2580d3a",
|
"rev": "1ccd39ac6de09a7a73a9a36ec1c34f70cb5edfe2",
|
||||||
"shallow": true,
|
"shallow": true,
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "ssh://git@git.epha.se:24422/ephase/nix-private.git"
|
"url": "ssh://git@git.epha.se:24422/ephase/nix-private.git"
|
||||||
|
@ -87,11 +84,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1752054764,
|
"lastModified": 1713543440,
|
||||||
"narHash": "sha256-Ob/HuUhANoDs+nvYqyTKrkcPXf4ZgXoqMTQoCK0RFgQ=",
|
"narHash": "sha256-lnzZQYG0+EXl/6NkGpyIz+FEOc/DSEG57AP1VsdeNrM=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "nixGL",
|
"repo": "nixGL",
|
||||||
"rev": "a8e1ce7d49a149ed70df676785b07f63288f53c5",
|
"rev": "310f8e49a149e4c9ea52f1adf70cdc768ec53f8a",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -116,11 +113,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1758690382,
|
"lastModified": 1748693115,
|
||||||
"narHash": "sha256-NY3kSorgqE5LMm1LqNwGne3ZLMF2/ILgLpFr1fS4X3o=",
|
"narHash": "sha256-StSrWhklmDuXT93yc3GrTlb0cKSS0agTAxMGjLKAsY8=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "e643668fd71b949c53f8626614b21ff71a07379d",
|
"rev": "910796cabe436259a29a72e8d3f5e180fc6dfacc",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -131,11 +128,11 @@
|
||||||
},
|
},
|
||||||
"nixpkgs_3": {
|
"nixpkgs_3": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1758690382,
|
"lastModified": 1748693115,
|
||||||
"narHash": "sha256-NY3kSorgqE5LMm1LqNwGne3ZLMF2/ILgLpFr1fS4X3o=",
|
"narHash": "sha256-StSrWhklmDuXT93yc3GrTlb0cKSS0agTAxMGjLKAsY8=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "e643668fd71b949c53f8626614b21ff71a07379d",
|
"rev": "910796cabe436259a29a72e8d3f5e180fc6dfacc",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -148,14 +145,15 @@
|
||||||
"nur": {
|
"nur": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-parts": "flake-parts",
|
"flake-parts": "flake-parts",
|
||||||
"nixpkgs": "nixpkgs_3"
|
"nixpkgs": "nixpkgs_3",
|
||||||
|
"treefmt-nix": "treefmt-nix"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1758828503,
|
"lastModified": 1748973087,
|
||||||
"narHash": "sha256-IgOibVOqWSZqWsHKK6TuALfuItRymW2YpsdZBjU2yrk=",
|
"narHash": "sha256-ZN0XKKdCBC9eLeog7qYhfGPbajkPtQPdlxp/dhwONw4=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "NUR",
|
"repo": "NUR",
|
||||||
"rev": "544f12f6987ceb94fe2052696da65623c238da4c",
|
"rev": "90add46380908ba4395f5f1dfec84224a3b0d4b9",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -181,11 +179,11 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1758425756,
|
"lastModified": 1747603214,
|
||||||
"narHash": "sha256-L3N8zV6wsViXiD8i3WFyrvjDdz76g3tXKEdZ4FkgQ+Y=",
|
"narHash": "sha256-lAblXm0VwifYCJ/ILPXJwlz0qNY07DDYdLD+9H+Wc8o=",
|
||||||
"owner": "Mic92",
|
"owner": "Mic92",
|
||||||
"repo": "sops-nix",
|
"repo": "sops-nix",
|
||||||
"rev": "e0fdaea3c31646e252a60b42d0ed8eafdb289762",
|
"rev": "8d215e1c981be3aa37e47aeabd4e61bb069548fd",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -194,18 +192,24 @@
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"systems": {
|
"treefmt-nix": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nur",
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1681028828,
|
"lastModified": 1733222881,
|
||||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
"narHash": "sha256-JIPcz1PrpXUCbaccEnrcUS8jjEb/1vJbZz5KkobyFdM=",
|
||||||
"owner": "nix-systems",
|
"owner": "numtide",
|
||||||
"repo": "default",
|
"repo": "treefmt-nix",
|
||||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
"rev": "49717b5af6f80172275d47a418c9719a31a78b53",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nix-systems",
|
"owner": "numtide",
|
||||||
"repo": "default",
|
"repo": "treefmt-nix",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
89
flake.nix
89
flake.nix
|
@ -9,7 +9,7 @@
|
||||||
};
|
};
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager";
|
url = "github:nix-community/home-manager";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
sops-nix = {
|
sops-nix = {
|
||||||
url = "github:Mic92/sops-nix";
|
url = "github:Mic92/sops-nix";
|
||||||
|
@ -19,52 +19,36 @@
|
||||||
url = "git+ssh://git@git.epha.se:24422/ephase/nix-private.git?shallow=1&ref=main";
|
url = "git+ssh://git@git.epha.se:24422/ephase/nix-private.git?shallow=1&ref=main";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
outputs = {
|
outputs = { self, nixpkgs, home-manager, nur, nixgl, sops-nix, ... }@inputs:
|
||||||
self,
|
let
|
||||||
nixpkgs,
|
|
||||||
home-manager,
|
|
||||||
nur,
|
|
||||||
nixgl,
|
|
||||||
sops-nix,
|
|
||||||
...
|
|
||||||
} @ inputs: let
|
|
||||||
stateVersion = "23.11";
|
stateVersion = "23.11";
|
||||||
|
|
||||||
allSystems = [
|
allSystems = [
|
||||||
"x86_64-linux" # 64bit AMD/Intel x86
|
"x86_64-linux" # 64bit AMD/Intel x86
|
||||||
"aarch64-linux" # 64bit ARM Linux
|
"aarch64-linux" # 64bit ARM Linux
|
||||||
];
|
];
|
||||||
|
|
||||||
forAllSystems = fn:
|
forAllSystems = fn:
|
||||||
nixpkgs.lib.genAttrs allSystems
|
nixpkgs.lib.genAttrs allSystems
|
||||||
(system: fn {pkgs = import nixpkgs {inherit system;};});
|
(system: fn { pkgs = import nixpkgs { inherit system; }; });
|
||||||
|
|
||||||
createNixosSystem = {
|
createNixosSystem = { system, hostname, username ? "ephase" }: nixpkgs.lib.nixosSystem {
|
||||||
system,
|
system = system;
|
||||||
hostname,
|
specialArgs = {
|
||||||
username ? "ephase",
|
inherit stateVersion inputs;
|
||||||
}:
|
hostname = hostname;
|
||||||
nixpkgs.lib.nixosSystem {
|
username = username;
|
||||||
system = system;
|
|
||||||
specialArgs = {
|
|
||||||
inherit stateVersion inputs;
|
|
||||||
hostname = hostname;
|
|
||||||
username = username;
|
|
||||||
};
|
|
||||||
modules = [
|
|
||||||
./nixos/default.nix
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
|
modules = [
|
||||||
|
./nixos/default.nix
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
createHomeConfiguration = {
|
createHomeConfiguration = { system ? "x86_64-linux", hostname, username ? "ephase" }:
|
||||||
system ? "x86_64-linux",
|
|
||||||
hostname,
|
|
||||||
username ? "ephase",
|
|
||||||
}:
|
|
||||||
home-manager.lib.homeManagerConfiguration {
|
home-manager.lib.homeManagerConfiguration {
|
||||||
pkgs = import nixpkgs {
|
pkgs = import nixpkgs {
|
||||||
system = system;
|
system = system;
|
||||||
overlays = [nixgl.overlay];
|
overlays = [ nixgl.overlay ];
|
||||||
};
|
};
|
||||||
extraSpecialArgs = {
|
extraSpecialArgs = {
|
||||||
inherit stateVersion inputs nixgl;
|
inherit stateVersion inputs nixgl;
|
||||||
|
@ -72,12 +56,12 @@
|
||||||
username = username;
|
username = username;
|
||||||
};
|
};
|
||||||
modules = [
|
modules = [
|
||||||
{nixpkgs.overlays = [nixgl.overlay];}
|
{ nixpkgs.overlays = [ nixgl.overlay ];}
|
||||||
./home-manager/default.nix
|
./home-manager/default.nix
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
devShells = forAllSystems ({pkgs}: {
|
devShells = forAllSystems ({ pkgs }: {
|
||||||
default = pkgs.mkShell {
|
default = pkgs.mkShell {
|
||||||
name = "nixfiles";
|
name = "nixfiles";
|
||||||
buildInputs = [
|
buildInputs = [
|
||||||
|
@ -94,36 +78,15 @@
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
morty = createNixosSystem {
|
morty = createNixosSystem { system = "x86_64-linux"; hostname = "morty"; };
|
||||||
system = "x86_64-linux";
|
mrmeeseeks = createNixosSystem { system = "x86_64-linux"; hostname = "mrmeeseeks";};
|
||||||
hostname = "morty";
|
luci = createNixosSystem { system = "x86_64-linux"; hostname = "luci"; };
|
||||||
};
|
|
||||||
mrmeeseeks = createNixosSystem {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
hostname = "mrmeeseeks";
|
|
||||||
};
|
|
||||||
luci = createNixosSystem {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
hostname = "luci";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
homeConfigurations = {
|
homeConfigurations = {
|
||||||
"rick" = createHomeConfiguration {
|
"rick" = createHomeConfiguration { system = "aarch64-linux"; hostname = "rick";};
|
||||||
system = "aarch64-linux";
|
"luci" = createHomeConfiguration { system = "x86_64-linux"; hostname = "luci";};
|
||||||
hostname = "rick";
|
"morty" = createHomeConfiguration { system = "x86_64-linux"; hostname = "morty";};
|
||||||
};
|
"mrmeeseeks" = createHomeConfiguration { system = "x86_64-linux"; hostname = "mrmeeseeks";};
|
||||||
"luci" = createHomeConfiguration {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
hostname = "luci";
|
|
||||||
};
|
|
||||||
"morty" = createHomeConfiguration {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
hostname = "morty";
|
|
||||||
};
|
|
||||||
"mrmeeseeks" = createHomeConfiguration {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
hostname = "mrmeeseeks";
|
|
||||||
};
|
|
||||||
"work" = createHomeConfiguration {
|
"work" = createHomeConfiguration {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
hostname = "work";
|
hostname = "work";
|
||||||
|
|
|
@ -1,23 +1,13 @@
|
||||||
|
{ inputs, lib, stateVersion, username, hostname, nixgl, ... }:
|
||||||
{
|
{
|
||||||
inputs,
|
imports = [
|
||||||
lib,
|
inputs.sops-nix.homeManagerModules.sops
|
||||||
stateVersion,
|
../hosts/${hostname}/home-config.nix
|
||||||
username,
|
../nixos/includes/system/overlay.nix
|
||||||
hostname,
|
../modules/home-manager/default.nix
|
||||||
nixgl,
|
] ++ lib.optional (
|
||||||
...
|
builtins.pathExists ../hosts/${hostname}/includes/home-manager.nix
|
||||||
}: {
|
) ../hosts/${hostname}/includes/home-manager.nix;
|
||||||
imports =
|
|
||||||
[
|
|
||||||
inputs.sops-nix.homeManagerModules.sops
|
|
||||||
../hosts/${hostname}/home-config.nix
|
|
||||||
../nixos/includes/system/overlay.nix
|
|
||||||
../modules/home-manager/default.nix
|
|
||||||
]
|
|
||||||
++ lib.optional (
|
|
||||||
builtins.pathExists ../hosts/${hostname}/includes/home-manager.nix
|
|
||||||
)
|
|
||||||
../hosts/${hostname}/includes/home-manager.nix;
|
|
||||||
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
programs.home-manager.enable = true;
|
programs.home-manager.enable = true;
|
||||||
|
|
|
@ -1,49 +1,45 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
# and may be overwritten by future invocations. Please make changes
|
# and may be overwritten by future invocations. Please make changes
|
||||||
# to /etc/nixos/configuration.nix instead.
|
# to /etc/nixos/configuration.nix instead.
|
||||||
{
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
modulesPath,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
|
||||||
(modulesPath + "/installer/scan/not-detected.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = ["xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" "i915"];
|
{
|
||||||
boot.initrd.kernelModules = [];
|
imports =
|
||||||
boot.kernelParams = ["intel_pstate=disable"];
|
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||||
boot.kernelModules = ["kvm-intel" "i915"];
|
];
|
||||||
boot.extraModulePackages = [];
|
|
||||||
|
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" "i915" ];
|
||||||
|
boot.initrd.kernelModules = [ ];
|
||||||
|
boot.kernelParams = [ "intel_pstate=disable" ];
|
||||||
|
boot.kernelModules = [ "kvm-intel" "i915" ];
|
||||||
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
boot.initrd.luks.devices."nixos".device = "/dev/disk/by-uuid/ee06e049-e738-4f1f-84ab-e8066e0f1640";
|
boot.initrd.luks.devices."nixos".device = "/dev/disk/by-uuid/ee06e049-e738-4f1f-84ab-e8066e0f1640";
|
||||||
|
|
||||||
fileSystems."/" = {
|
fileSystems."/" =
|
||||||
device = "/dev/disk/by-uuid/97c3403a-fdad-4dc8-a103-a666d5fd8d6c";
|
{ device = "/dev/disk/by-uuid/97c3403a-fdad-4dc8-a103-a666d5fd8d6c";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=root" "compress=zstd"];
|
options = [ "subvol=root" "compress=zstd" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/home" = {
|
fileSystems."/home" =
|
||||||
device = "/dev/disk/by-uuid/97c3403a-fdad-4dc8-a103-a666d5fd8d6c";
|
{ device = "/dev/disk/by-uuid/97c3403a-fdad-4dc8-a103-a666d5fd8d6c";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=home" "compress=zstd"];
|
options = [ "subvol=home" "compress=zstd"];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/nix" = {
|
fileSystems."/nix" =
|
||||||
device = "/dev/disk/by-uuid/97c3403a-fdad-4dc8-a103-a666d5fd8d6c";
|
{ device = "/dev/disk/by-uuid/97c3403a-fdad-4dc8-a103-a666d5fd8d6c";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=nix" "compress=zstd"];
|
options = [ "subvol=nix" "compress=zstd"];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
fileSystems."/boot" =
|
||||||
device = "/dev/disk/by-uuid/B77A-53B1";
|
{ device = "/dev/disk/by-uuid/B77A-53B1";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [];
|
swapDevices = [ ];
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
# 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
|
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||||
|
@ -64,5 +60,5 @@
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
virtualisation.docker.enable = true;
|
virtualisation.docker.enable = true;
|
||||||
users.extraGroups.docker.members = ["ephase"];
|
users.extraGroups.docker.members = [ "ephase" ];
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{...}: {
|
{ ... }: {
|
||||||
config.modules = {
|
config.modules = {
|
||||||
application = {
|
application = {
|
||||||
gnupg.enable = true;
|
gnupg.enable = true;
|
||||||
|
@ -29,7 +29,7 @@
|
||||||
accounts.dav.enable = true;
|
accounts.dav.enable = true;
|
||||||
desktop.sway = {
|
desktop.sway = {
|
||||||
enable = true;
|
enable = true;
|
||||||
kanshi.enable = true;
|
kanshi = true;
|
||||||
wallpapers.lockscreen = "${./files/lockscreen.png}";
|
wallpapers.lockscreen = "${./files/lockscreen.png}";
|
||||||
wallpapers.desktop = "${./files/wallpaper.png} center #000000";
|
wallpapers.desktop = "${./files/wallpaper.png} center #000000";
|
||||||
waybar = {
|
waybar = {
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
{...}: {
|
{ ... }:
|
||||||
|
{
|
||||||
## Specific host home manager configuration
|
## Specific host home manager configuration
|
||||||
wayland.windowManager.sway.config = {
|
wayland.windowManager.sway.config = {
|
||||||
input = {
|
input = {
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{...}: {
|
{ ... }: {
|
||||||
config.modules.desktop.sway.enable = true;
|
config.modules.desktop.sway.enable = true;
|
||||||
config.modules.gaming.steam.enable = false;
|
config.modules.gaming.steam.enable = false;
|
||||||
config.modules.hardware.laptop.enable = true;
|
config.modules.hardware.laptop.enable = true;
|
||||||
|
|
|
@ -1,49 +1,45 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
# and may be overwritten by future invocations. Please make changes
|
# and may be overwritten by future invocations. Please make changes
|
||||||
# to /etc/nixos/configuration.nix instead.
|
# to /etc/nixos/configuration.nix instead.
|
||||||
{
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
modulesPath,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
|
||||||
(modulesPath + "/installer/scan/not-detected.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "nvme" "usb_storage" "usbhid" "sd_mod" "i915"];
|
{
|
||||||
boot.initrd.kernelModules = [];
|
imports =
|
||||||
boot.kernelModules = ["kvm-intel" "i915"];
|
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||||
boot.extraModulePackages = [];
|
];
|
||||||
boot.kernelParams = ["fbcon=rotate:1" "video=eDP-1:panel_orientation=right_side_up" "intel_pstate=disable"];
|
|
||||||
|
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usb_storage" "usbhid" "sd_mod" "i915" ];
|
||||||
|
boot.initrd.kernelModules = [ ];
|
||||||
|
boot.kernelModules = [ "kvm-intel" "i915" ];
|
||||||
|
boot.extraModulePackages = [ ];
|
||||||
|
boot.kernelParams = ["fbcon=rotate:1" "video=eDP-1:panel_orientation=right_side_up" "intel_pstate=disable" ];
|
||||||
boot.loader.systemd-boot.consoleMode = "max";
|
boot.loader.systemd-boot.consoleMode = "max";
|
||||||
fileSystems."/" = {
|
fileSystems."/" =
|
||||||
device = "/dev/disk/by-uuid/d28d59b0-a44d-4b17-9338-2ca69a1efca7";
|
{ device = "/dev/disk/by-uuid/d28d59b0-a44d-4b17-9338-2ca69a1efca7";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=root" "compress=zstd"];
|
options = [ "subvol=root" "compress=zstd"];
|
||||||
};
|
};
|
||||||
|
|
||||||
boot.initrd.luks.devices."nixos".device = "/dev/disk/by-uuid/ad4fa799-214c-4e5e-996a-8776e010fb2f";
|
boot.initrd.luks.devices."nixos".device = "/dev/disk/by-uuid/ad4fa799-214c-4e5e-996a-8776e010fb2f";
|
||||||
|
|
||||||
fileSystems."/nix" = {
|
fileSystems."/nix" =
|
||||||
device = "/dev/disk/by-uuid/d28d59b0-a44d-4b17-9338-2ca69a1efca7";
|
{ device = "/dev/disk/by-uuid/d28d59b0-a44d-4b17-9338-2ca69a1efca7";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=nix" "compress=zstd"];
|
options = [ "subvol=nix" "compress=zstd" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/home" = {
|
fileSystems."/home" =
|
||||||
device = "/dev/disk/by-uuid/d28d59b0-a44d-4b17-9338-2ca69a1efca7";
|
{ device = "/dev/disk/by-uuid/d28d59b0-a44d-4b17-9338-2ca69a1efca7";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=home" "compress=zstd"];
|
options = [ "subvol=home" "compress=zstd" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
fileSystems."/boot" =
|
||||||
device = "/dev/disk/by-uuid/E83D-CDFE";
|
{ device = "/dev/disk/by-uuid/E83D-CDFE";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [];
|
swapDevices = [ ];
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
{inputs, ...}: {
|
{ inputs, ... }: {
|
||||||
config.modules = {
|
config.modules = {
|
||||||
email = {
|
email = {
|
||||||
enable = true;
|
enable = true;
|
||||||
accountConfigs = {
|
accountConfigs = {
|
||||||
"1" = inputs.nix-private.mail.xiemeart;
|
a = inputs.nix-private.mail.xiemeart;
|
||||||
"2" = inputs.nix-private.mail.ephase;
|
b = inputs.nix-private.mail.ephase;
|
||||||
"3" = inputs.nix-private.mail.ubordeaux;
|
c = inputs.nix-private.mail.ubordeaux;
|
||||||
};
|
};
|
||||||
primary = "1";
|
primary = "a";
|
||||||
};
|
};
|
||||||
dav.enable = true;
|
dav.enable = true;
|
||||||
application = {
|
application = {
|
||||||
|
@ -46,20 +46,7 @@
|
||||||
desktop.sway = {
|
desktop.sway = {
|
||||||
enable = true;
|
enable = true;
|
||||||
wallpapers.lockscreen = "${./files/lockscreen.png}";
|
wallpapers.lockscreen = "${./files/lockscreen.png}";
|
||||||
kanshi = {
|
kanshi = true;
|
||||||
enable = true;
|
|
||||||
standalone = {
|
|
||||||
profile.name = "standalone";
|
|
||||||
profile.outputs = [
|
|
||||||
{
|
|
||||||
criteria = "eDP-1";
|
|
||||||
scale = 1.325;
|
|
||||||
transform = "270";
|
|
||||||
status = "enable";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
waybar = {
|
waybar = {
|
||||||
laptop = true;
|
laptop = true;
|
||||||
gpuThermal.enable = false;
|
gpuThermal.enable = false;
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
{...}: {
|
{ ... }:
|
||||||
home.file.".config/xkb/symbols/gpdwinmax".text = ''
|
{
|
||||||
|
home.file.".config/xkb/symbols/gpdwinmax".text =
|
||||||
|
''
|
||||||
default partial alphanumeric_keys
|
default partial alphanumeric_keys
|
||||||
xkb_symbols "us-intl-winmax" {
|
xkb_symbols "us-intl-winmax" {
|
||||||
name[group1] = "GPD Win Max us-inlt";
|
name[group1] = "GPD Win Max us-inlt";
|
||||||
|
@ -22,5 +24,11 @@
|
||||||
"pointer_accel" = "0.3";
|
"pointer_accel" = "0.3";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
wayland.windowManager.sway.config.output = {
|
||||||
|
"eDP-1" = {
|
||||||
|
transform = "90";
|
||||||
|
scale = "1.3";
|
||||||
|
};
|
||||||
|
};
|
||||||
sops.age.keyFile = "/home/ephase/.config/sops/age/keys.txt";
|
sops.age.keyFile = "/home/ephase/.config/sops/age/keys.txt";
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{...}: {
|
{ ... }: {
|
||||||
config.modules.desktop.sway.enable = true;
|
config.modules.desktop.sway.enable = true;
|
||||||
config.modules.gaming.steam.enable = true;
|
config.modules.gaming.steam.enable = true;
|
||||||
config.modules.hardware.laptop = {
|
config.modules.hardware.laptop = {
|
||||||
|
|
|
@ -1,65 +1,61 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
# and may be overwritten by future invocations. Please make changes
|
# and may be overwritten by future invocations. Please make changes
|
||||||
# to /etc/nixos/configuration.nix instead.
|
# to /etc/nixos/configuration.nix instead.
|
||||||
{
|
{ config, lib, pkgs, modulesPath, ... }:
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
pkgs,
|
|
||||||
modulesPath,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
|
||||||
(modulesPath + "/installer/scan/not-detected.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [
|
{
|
||||||
|
imports =
|
||||||
|
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||||
|
];
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules = [
|
||||||
"nvme"
|
"nvme"
|
||||||
"xhci_pci"
|
"xhci_pci"
|
||||||
"ahci"
|
"ahci"
|
||||||
"usbhid"
|
"usbhid"
|
||||||
"usb_storage"
|
"usb_storage"
|
||||||
"sd_mod"
|
"sd_mod"
|
||||||
"amdgpu"
|
"amdgpu"
|
||||||
];
|
];
|
||||||
boot.initrd.kernelModules = [
|
boot.initrd.kernelModules = [
|
||||||
"dm-cache-default"
|
"dm-cache-default"
|
||||||
];
|
];
|
||||||
boot.kernelModules = [
|
boot.kernelModules = [
|
||||||
"kvm-amd"
|
"kvm-amd"
|
||||||
"amdgpu"
|
"amdgpu"
|
||||||
];
|
];
|
||||||
|
|
||||||
boot.kernelParams = [
|
boot.kernelParams = [
|
||||||
"amdgpu.ppfeaturemask=0xffffffff"
|
"amdgpu.ppfeaturemask=0xffffffff"
|
||||||
];
|
];
|
||||||
|
|
||||||
boot.extraModulePackages = [];
|
boot.extraModulePackages = [ ];
|
||||||
boot.initrd.luks.devices."nixos".device = "/dev/disk/by-uuid/ea7fa60d-35e5-48b8-95d7-142f37b262cd";
|
boot.initrd.luks.devices."nixos".device = "/dev/disk/by-uuid/ea7fa60d-35e5-48b8-95d7-142f37b262cd";
|
||||||
boot.initrd.luks.devices."nixos".preLVM = true;
|
boot.initrd.luks.devices."nixos".preLVM = true;
|
||||||
|
|
||||||
fileSystems."/" = {
|
fileSystems."/" =
|
||||||
device = "/dev/disk/by-uuid/9d1e5022-0265-4ce7-824e-282ee550d52d";
|
{ device = "/dev/disk/by-uuid/9d1e5022-0265-4ce7-824e-282ee550d52d";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=@root" "compress=zstd"];
|
options = [ "subvol=@root" "compress=zstd"];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/home" = {
|
fileSystems."/home" =
|
||||||
device = "/dev/disk/by-uuid/9d1e5022-0265-4ce7-824e-282ee550d52d";
|
{ device = "/dev/disk/by-uuid/9d1e5022-0265-4ce7-824e-282ee550d52d";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=@home" "compress=zstd"];
|
options = [ "subvol=@home" "compress=zstd"];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot" = {
|
fileSystems."/boot" =
|
||||||
device = "/dev/disk/by-uuid/F027-F53F";
|
{ device = "/dev/disk/by-uuid/F027-F53F";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/mnt/gamelib" = {
|
fileSystems."/mnt/gamelib" =
|
||||||
device = "/dev/mapper/tank-gamelib";
|
{ device = "/dev/mapper/tank-gamelib";
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [];
|
swapDevices = [ ];
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
# 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
|
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||||
|
@ -70,7 +66,7 @@
|
||||||
# networking.interfaces.wlp37s0.useDHCP = lib.mkDefault true;
|
# networking.interfaces.wlp37s0.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
|
|
||||||
hardware.cpu.amd.updateMicrocode = true;
|
hardware.cpu.amd.updateMicrocode = true;
|
||||||
hardware.graphics = {
|
hardware.graphics = {
|
||||||
enable32Bit = true;
|
enable32Bit = true;
|
||||||
|
|
|
@ -1,10 +1,7 @@
|
||||||
{inputs, ...}: {
|
{ ... }: {
|
||||||
config.modules = {
|
config.modules = {
|
||||||
application = {
|
application = {
|
||||||
gnupg = {
|
gnupg.enable = true;
|
||||||
enable = true;
|
|
||||||
enableSshSupport = true;
|
|
||||||
};
|
|
||||||
zathura.enable = true;
|
zathura.enable = true;
|
||||||
foot.enable = true;
|
foot.enable = true;
|
||||||
};
|
};
|
||||||
|
@ -14,10 +11,7 @@
|
||||||
git.enable = true;
|
git.enable = true;
|
||||||
neovim.enable = true;
|
neovim.enable = true;
|
||||||
starship.enable = true;
|
starship.enable = true;
|
||||||
tmux = {
|
tmux.enable = true;
|
||||||
enable = true;
|
|
||||||
extraConfig = inputs.nix-private.tmux.personal;
|
|
||||||
};
|
|
||||||
utils.enable = true;
|
utils.enable = true;
|
||||||
vifm.enable = true;
|
vifm.enable = true;
|
||||||
zsh.enable = true;
|
zsh.enable = true;
|
||||||
|
|
|
@ -3,14 +3,14 @@ _: {
|
||||||
wayland.windowManager.sway.config.output = {
|
wayland.windowManager.sway.config.output = {
|
||||||
"Iiyama North America PL2792UH 1166310803122" = {
|
"Iiyama North America PL2792UH 1166310803122" = {
|
||||||
max_render_time = "5";
|
max_render_time = "5";
|
||||||
mode = "3840x2160@60Hz";
|
mode = "3840x2160@60Hz";
|
||||||
position = "1235,0";
|
position = "1235,0";
|
||||||
scale = "1.75";
|
scale = "1.75";
|
||||||
bg = "~/medias/images/wallpapers/desktop.jpg center #000000";
|
bg = "~/medias/images/wallpapers/desktop.jpg center #000000";
|
||||||
};
|
};
|
||||||
"Iiyama North America PL2792UH 1176923201598" = {
|
"Iiyama North America PL2792UH 1176923201598" = {
|
||||||
max_render_time = "5";
|
max_render_time = "5";
|
||||||
mode = "3840x2160@60Hz";
|
mode = "3840x2160@60Hz";
|
||||||
position = "0,0";
|
position = "0,0";
|
||||||
scale = "1.75";
|
scale = "1.75";
|
||||||
transform = "270";
|
transform = "270";
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
{...}: {
|
{ ... }: {
|
||||||
config.modules.desktop.sway.enable = true;
|
config.modules.desktop.sway.enable = true;
|
||||||
config.modules.gaming.steam = {
|
config.modules.gaming.steam = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
|
@ -1,14 +1,10 @@
|
||||||
{
|
{ pkgs, ... }: {
|
||||||
pkgs,
|
|
||||||
inputs,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
config.modules = {
|
config.modules = {
|
||||||
application = {
|
application = {
|
||||||
gnupg.enable = true;
|
gnupg.enable = false;
|
||||||
zathura.enable = true;
|
zathura.enable = true;
|
||||||
foot.enable = true;
|
foot.enable = false;
|
||||||
imv.enable = true;
|
imv.enable = false;
|
||||||
};
|
};
|
||||||
audio = {
|
audio = {
|
||||||
cmus.enable = true;
|
cmus.enable = true;
|
||||||
|
@ -16,11 +12,7 @@
|
||||||
cli = {
|
cli = {
|
||||||
direnv.enable = true;
|
direnv.enable = true;
|
||||||
ghq.enable = true;
|
ghq.enable = true;
|
||||||
git = {
|
git.enable = true;
|
||||||
enable = true;
|
|
||||||
userEmail = inputs.nix-private.git.personal.userEmail;
|
|
||||||
signingKey = inputs.nix-private.git.personal.signingKey;
|
|
||||||
};
|
|
||||||
neovim.enable = true;
|
neovim.enable = true;
|
||||||
starship.enable = true;
|
starship.enable = true;
|
||||||
tmux.enable = true;
|
tmux.enable = true;
|
||||||
|
@ -37,9 +29,8 @@
|
||||||
web.webcord.enable = false;
|
web.webcord.enable = false;
|
||||||
gaming.lutris.enable = false;
|
gaming.lutris.enable = false;
|
||||||
desktop.sway = {
|
desktop.sway = {
|
||||||
enable = true;
|
enable = false;
|
||||||
kanshi.enable = false;
|
kanshi = false;
|
||||||
swaylock.useNullPackage = true;
|
|
||||||
wallpapers.lockscreen = "${./files/lockscreen.png}";
|
wallpapers.lockscreen = "${./files/lockscreen.png}";
|
||||||
wallpapers.desktop = "${./files/background.png} fill #000000";
|
wallpapers.desktop = "${./files/background.png} fill #000000";
|
||||||
waybar = {
|
waybar = {
|
||||||
|
@ -48,7 +39,7 @@
|
||||||
enable = false;
|
enable = false;
|
||||||
};
|
};
|
||||||
cpuThermal = {
|
cpuThermal = {
|
||||||
thermalZone = 2;
|
thermalZone = "2";
|
||||||
# hwmonPathAbs = "";
|
# hwmonPathAbs = "";
|
||||||
# inputFilename = "";
|
# inputFilename = "";
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,23 +1,21 @@
|
||||||
_: {
|
_:
|
||||||
wayland.windowManager.sway.config.output = {
|
{
|
||||||
"eDP-1" = {
|
|
||||||
scale = "1.4";
|
|
||||||
};
|
|
||||||
"HDMI-A-1" = {
|
|
||||||
disable = "";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
wayland.windowManager.sway.config.input = {
|
|
||||||
"4617:27904:MNT_Research_MNT_Reform_Keyboard_2.0_US/LT" = {
|
|
||||||
xkb_layout = "us";
|
|
||||||
xkb_variant = "altgr-intl";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
programs.zsh.loginExtra = ''
|
programs.zsh.loginExtra = ''
|
||||||
# notmuch
|
#notmutch
|
||||||
export NOTMUCH_CONFIG="$HOME/.config/notmuch/config"
|
export NOTMUCH_CONFIG="$HOME/.config/notmuch/config"
|
||||||
# export PATH=~/.local/bin:$PATH
|
export PATH=~/.local/bin:$PATH
|
||||||
# export XDG_DATA_HOME=$HOME/.local/share
|
# export XDG_DATA_HOME=$HOME/.local/share
|
||||||
unset DEBUGINFOD_URLS
|
unset DEBUGINFOD_URLS
|
||||||
'';
|
if [[ ! $DISPLAY && $XDG_VTNR -eq 1 ]]; then
|
||||||
}
|
export QT_QPA_PLATFORM="wayland-egl"
|
||||||
|
export QT_WAYLAND_DISABLE_WINDOWDECORATION=1
|
||||||
|
export MOZ_ENABLE_WAYLAND=1
|
||||||
|
export QT_QPA_PLATFORMTHEME=qt5ct
|
||||||
|
export NO_AT_BRIDGE=1
|
||||||
|
export XDG_SESSION_TYPE=wayland
|
||||||
|
export XDG_CURRENT_DESKTOP=sway
|
||||||
|
export SSH_AUTH_SOCK=$XDG_RUNTIME_DIR/ssh-agent.socket
|
||||||
|
exec ~/.local/bin/sway.sh
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
}
|
||||||
|
|
|
@ -1,8 +1,4 @@
|
||||||
{
|
{ pkgs, inputs, ... }: {
|
||||||
pkgs,
|
|
||||||
inputs,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
config.modules = {
|
config.modules = {
|
||||||
application = {
|
application = {
|
||||||
zathura.enable = true;
|
zathura.enable = true;
|
||||||
|
@ -36,34 +32,14 @@
|
||||||
};
|
};
|
||||||
desktop.sway = {
|
desktop.sway = {
|
||||||
enable = true;
|
enable = true;
|
||||||
kanshi = {
|
kanshi = true;
|
||||||
enable = true;
|
|
||||||
profiles = [
|
|
||||||
|
|
||||||
{
|
|
||||||
profile.name = "work";
|
|
||||||
profile.outputs = [
|
|
||||||
{
|
|
||||||
criteria = "Iiyama North America PL2792QN 1179214201663";
|
|
||||||
mode = "2560x1440";
|
|
||||||
position = "1450,0";
|
|
||||||
scale = 1.15;
|
|
||||||
}
|
|
||||||
{
|
|
||||||
criteria = "BOE 0x0A95 Unknown";
|
|
||||||
mode = "1920x1080";
|
|
||||||
position = "0,0";
|
|
||||||
scale = 1.325;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
||||||
];
|
|
||||||
swaylock.useNullPackage = true;
|
swaylock.useNullPackage = true;
|
||||||
waybar = {
|
waybar = {
|
||||||
laptop = true;
|
laptop = true;
|
||||||
gpuThermal.enable = false;
|
gpuThermal.enable = false;
|
||||||
cpuThermal = {
|
cpuThermal = {
|
||||||
thermalZone = 9;
|
hwmonPathAbs = "/sys/devices/platform/coretemp.0/hwmon/";
|
||||||
|
inputFilename = "temp1_input";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
xdg.useDistributionPortals = true;
|
xdg.useDistributionPortals = true;
|
||||||
|
|
|
@ -1,27 +1,24 @@
|
||||||
|
{ pkgs, config, ... }:
|
||||||
{
|
{
|
||||||
pkgs,
|
home.packages = with pkgs; [
|
||||||
config,
|
dejavu_fonts
|
||||||
...
|
font-awesome
|
||||||
}: {
|
lato
|
||||||
home.packages = with pkgs; [
|
liberation_ttf
|
||||||
dejavu_fonts
|
libertine
|
||||||
font-awesome
|
libnotify
|
||||||
lato
|
nerd-fonts.fira-code
|
||||||
liberation_ttf
|
nerd-fonts.fira-mono
|
||||||
libertine
|
noto-fonts-emoji
|
||||||
libnotify
|
noto-fonts-cjk-sans
|
||||||
nerd-fonts.fira-code
|
slurp
|
||||||
nerd-fonts.fira-mono
|
wl-clipboard
|
||||||
noto-fonts-emoji
|
(config.lib.nixGL.wrap ungoogled-chromium)
|
||||||
noto-fonts-cjk-sans
|
(config.lib.nixGL.wrap slack)
|
||||||
slurp
|
];
|
||||||
wl-clipboard
|
targets.genericLinux.enable = true;
|
||||||
(config.lib.nixGL.wrap ungoogled-chromium)
|
xdg.mime.enable = true;
|
||||||
(config.lib.nixGL.wrap slack)
|
wayland.windowManager.sway.config.input = {
|
||||||
];
|
|
||||||
targets.genericLinux.enable = true;
|
|
||||||
xdg.mime.enable = true;
|
|
||||||
wayland.windowManager.sway.config.input = {
|
|
||||||
"1:1:AT_Translated_Set_2_keyboard" = {
|
"1:1:AT_Translated_Set_2_keyboard" = {
|
||||||
xkb_layout = "us";
|
xkb_layout = "us";
|
||||||
xkb_variant = "altgr-intl";
|
xkb_variant = "altgr-intl";
|
||||||
|
|
|
@ -1,26 +1,23 @@
|
||||||
{
|
{ lib, config, inputs, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
inputs,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.dav;
|
cfg = config.modules.dav;
|
||||||
secretsDirectory = "${(builtins.toString inputs.nix-private)}/secrets";
|
secretsDirectory = "${(builtins.toString inputs.nix-private)}/secrets";
|
||||||
vdirsyncerConf = {
|
vdirsyncerConf = {
|
||||||
enable = true;
|
enable = true;
|
||||||
auth = "basic";
|
auth = "basic";
|
||||||
};
|
};
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.dav = {
|
options.modules.dav = {
|
||||||
enable = mkEnableOption "enable personal Caldav / CardDav";
|
enable = mkEnableOption "enable personal Caldav / CardDav";
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
|
||||||
sops = {
|
sops = {
|
||||||
secrets = {
|
secrets = {
|
||||||
"${inputs.nix-private.dav.personal.secret.key}" = {
|
"${inputs.nix-private.dav.personal.secret.key}" = {
|
||||||
sopsFile = "${secretsDirectory}/${inputs.nix-private.dav.personal.secret.file}";
|
sopsFile = "${secretsDirectory}/${inputs.nix-private.dav.personal.secret.file}";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -37,22 +34,20 @@ in {
|
||||||
"${config.sops.secrets."${inputs.nix-private.dav.personal.secret.key}".path}"
|
"${config.sops.secrets."${inputs.nix-private.dav.personal.secret.key}".path}"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
vdirsyncer =
|
vdirsyncer = vdirsyncerConf // {
|
||||||
vdirsyncerConf
|
metadata = [
|
||||||
// {
|
"color"
|
||||||
metadata = [
|
"displayname"
|
||||||
"color"
|
];
|
||||||
"displayname"
|
itemTypes = [
|
||||||
];
|
"VTODO"
|
||||||
itemTypes = [
|
"VEVENT"
|
||||||
"VTODO"
|
];
|
||||||
"VEVENT"
|
collections = [
|
||||||
];
|
"from a"
|
||||||
collections = [
|
"from b"
|
||||||
"from a"
|
];
|
||||||
"from b"
|
};
|
||||||
];
|
|
||||||
};
|
|
||||||
khal = {
|
khal = {
|
||||||
enable = true;
|
enable = true;
|
||||||
type = "discover";
|
type = "discover";
|
||||||
|
@ -75,13 +70,11 @@ in {
|
||||||
type = "filesystem";
|
type = "filesystem";
|
||||||
fileExt = ".vcf";
|
fileExt = ".vcf";
|
||||||
};
|
};
|
||||||
vdirsyncer =
|
vdirsyncer = vdirsyncerConf // {
|
||||||
vdirsyncerConf
|
metadata = [
|
||||||
// {
|
"displayname"
|
||||||
metadata = [
|
];
|
||||||
"displayname"
|
};
|
||||||
];
|
|
||||||
};
|
|
||||||
khal = {
|
khal = {
|
||||||
enable = true;
|
enable = true;
|
||||||
color = "#26A269";
|
color = "#26A269";
|
||||||
|
@ -120,7 +113,7 @@ in {
|
||||||
general = {
|
general = {
|
||||||
default_action = "list";
|
default_action = "list";
|
||||||
editor = ["nvim" "-i" "NONE"];
|
editor = ["nvim" "-i" "NONE"];
|
||||||
merge_editor = ["nvim" "-d"];
|
merge_editor = [ "nvim" "-d" ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,14 +1,10 @@
|
||||||
{
|
{ lib, config, pkgs, inputs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
inputs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.email;
|
cfg = config.modules.email;
|
||||||
secretsDirectory = "${(builtins.toString inputs.nix-private)}/secrets";
|
secretsDirectory = "${(builtins.toString inputs.nix-private)}/secrets";
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.email = {
|
options.modules.email = {
|
||||||
enable = mkEnableOption "Enable email accounts configuration";
|
enable = mkEnableOption "Enable email accounts configuration";
|
||||||
|
|
||||||
|
@ -27,14 +23,11 @@ in {
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
sops = let
|
sops = let
|
||||||
secretList =
|
secretList = lib.mapAttrs' ( name: value:
|
||||||
lib.mapAttrs' (
|
nameValuePair ( value.secret.key ) ({
|
||||||
name: value:
|
sopsFile = "${secretsDirectory}/${value.secret.file}";
|
||||||
nameValuePair (value.secret.key) {
|
})
|
||||||
sopsFile = "${secretsDirectory}/${value.secret.file}";
|
) cfg.accountConfigs;
|
||||||
}
|
|
||||||
)
|
|
||||||
cfg.accountConfigs;
|
|
||||||
in {
|
in {
|
||||||
secrets = secretList;
|
secrets = secretList;
|
||||||
};
|
};
|
||||||
|
@ -62,32 +55,28 @@ in {
|
||||||
showDefaultMailbox = false;
|
showDefaultMailbox = false;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
accountsList = lib.mapAttrs (name: value: lib.recursiveUpdate defaultSetting value.config) cfg.accountConfigs;
|
accountsList = lib.mapAttrs ( name: value: lib.recursiveUpdate defaultSetting value.config ) cfg.accountConfigs;
|
||||||
in {
|
in {
|
||||||
maildirBasePath = "mail";
|
maildirBasePath = "mail";
|
||||||
accounts = lib.recursiveUpdate accountsList {"${cfg.primary}".primary = true;};
|
accounts = lib.recursiveUpdate accountsList { "${cfg.primary}".primary = true; };
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.afew = let
|
programs.afew = let
|
||||||
mailMoverRules = lib.mergeAttrsList (
|
mailMoverRules = lib.mergeAttrsList (
|
||||||
lib.attrsets.mapAttrsToList (
|
lib.attrsets.mapAttrsToList (
|
||||||
n: v:
|
n: v:
|
||||||
if lib.hasAttrByPath ["afew" "mailMover"] v
|
if lib.hasAttrByPath ["afew" "mailMover"] v then
|
||||||
then v.afew.mailMover
|
v.afew.mailMover
|
||||||
else {}
|
else {}
|
||||||
)
|
) cfg.accountConfigs);
|
||||||
cfg.accountConfigs
|
|
||||||
);
|
|
||||||
mailFilterRules = lib.flatten (
|
mailFilterRules = lib.flatten (
|
||||||
lib.attrsets.mapAttrsToList (
|
lib.attrsets.mapAttrsToList (
|
||||||
n: v:
|
n: v:
|
||||||
if lib.hasAttrByPath ["afew" "filters"] v
|
if lib.hasAttrByPath ["afew" "filters"] v then
|
||||||
then v.afew.filters
|
v.afew.filters
|
||||||
else []
|
else []
|
||||||
)
|
) cfg.accountConfigs);
|
||||||
cfg.accountConfigs
|
in {
|
||||||
);
|
|
||||||
in {
|
|
||||||
enable = true;
|
enable = true;
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
[FolderNameFilter]
|
[FolderNameFilter]
|
||||||
|
@ -107,20 +96,16 @@ in {
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
programs.neomutt = let
|
programs.neomutt = let
|
||||||
accountMacros =
|
accountMacros = lib.imap1 (
|
||||||
lib.imap1 (
|
i:
|
||||||
i: elem:
|
elem: elem // {
|
||||||
elem
|
map = ["index" "pager"];
|
||||||
// {
|
key = "<F${(toString (i + 1))}>";
|
||||||
map = ["index" "pager"];
|
}) (
|
||||||
key = "<F${(toString (i + 1))}>";
|
|
||||||
}
|
|
||||||
) (
|
|
||||||
lib.attrsets.mapAttrsToList (
|
lib.attrsets.mapAttrsToList (
|
||||||
n: c: {"action" = "<sync-mailbox><refresh><enter-command>source ~/.config/neomutt/${n}<enter><change-vfolder>Unread:${c.config.address}<enter>";}
|
n: c:
|
||||||
)
|
{ "action" = "<sync-mailbox><refresh><enter-command>source ~/.config/neomutt/${n}<enter><change-vfolder>Unread:${c.config.address}<enter>";}
|
||||||
cfg.accountConfigs
|
) cfg.accountConfigs);
|
||||||
);
|
|
||||||
in {
|
in {
|
||||||
enable = true;
|
enable = true;
|
||||||
unmailboxes = true;
|
unmailboxes = true;
|
||||||
|
@ -151,224 +136,94 @@ in {
|
||||||
envelope_from = "yes";
|
envelope_from = "yes";
|
||||||
use_envelope_from = "no";
|
use_envelope_from = "no";
|
||||||
my_status = "' %o/%m | %l | %f %* Sort: %s-%S Pos: %P '";
|
my_status = "' %o/%m | %l | %f %* Sort: %s-%S Pos: %P '";
|
||||||
my_pager = "' %F | %s %* Pos: %P '";
|
my_pager = "' %F | %s %* Pos: %P '";
|
||||||
compose_format = "' COMPOSE %a | %l'";
|
compose_format = "' COMPOSE %a | %l'";
|
||||||
query_command = "'${pkgs.khard}/bin/khard email --parsable --search-in-source-files %s'";
|
query_command = "'${pkgs.khard}/bin/khard email --parsable --search-in-source-files %s'";
|
||||||
virtual_spoolfile = "yes";
|
virtual_spoolfile = "yes";
|
||||||
mail_check_stats = "yes";
|
mail_check_stats = "yes";
|
||||||
mh_purge = "yes";
|
mh_purge = "yes";
|
||||||
mailcap_path = "${config.xdg.configHome}/neomutt/mailcap";
|
mailcap_path= "${config.xdg.configHome}/neomutt/mailcap";
|
||||||
};
|
};
|
||||||
extraConfig = ''
|
extraConfig = ''
|
||||||
${(builtins.readFile ./files/theme.muttrc)}
|
${(builtins.readFile ./files/theme.muttrc)}
|
||||||
set reverse_name
|
set reverse_name
|
||||||
charset-hook ^iso-8859-1$ cp1252
|
charset-hook ^iso-8859-1$ cp1252
|
||||||
ignore *
|
ignore *
|
||||||
|
|
||||||
unignore from date subject to cc bcc tags user-agent x-mailer
|
unignore from date subject to cc bcc tags user-agent x-mailer
|
||||||
|
|
||||||
# Attachment
|
# Attachment
|
||||||
auto_view text/x-vcard text/html text/enriched text/calendar
|
auto_view text/x-vcard text/html text/enriched text/calendar
|
||||||
alternative_order text/html text/enriched text/plain text/*
|
alternative_order text/html text/enriched text/plain text/*
|
||||||
|
|
||||||
tag-transforms "attachment" "" \
|
tag-transforms "attachment" "" \
|
||||||
"encrypted" "" \
|
"encrypted" "" \
|
||||||
"signed" "" \
|
"signed" "" \
|
||||||
"unread" "" \
|
"unread" "" \
|
||||||
"replied" ""
|
"replied" ""
|
||||||
tag-formats "attachment" "GA" \
|
tag-formats "attachment" "GA" \
|
||||||
"encrypted" "GE" \
|
"encrypted" "GE" \
|
||||||
"signed" "GS" \
|
"signed" "GS" \
|
||||||
"unread" "GU" \
|
"unread" "GU" \
|
||||||
"replied" "GR"
|
"replied" "GR"
|
||||||
|
|
||||||
${lib.concatStrings (lib.attrsets.mapAttrsToList (_: v:
|
${lib.concatStrings (lib.attrsets.mapAttrsToList ( _: v: if lib.hasAttrByPath [ "neomuttHooks" ] v then v.neomuttHooks else "" ) cfg.accountConfigs)}
|
||||||
if lib.hasAttrByPath ["neomuttHooks"] v
|
# manually source first account instead of use home-manager parameter because
|
||||||
then v.neomuttHooks
|
# of $my_pager expansion does not work as this variable is not already set
|
||||||
else "")
|
source ${config.xdg.configHome}/neomutt/${cfg.primary}
|
||||||
cfg.accountConfigs)}
|
|
||||||
# manually source first account instead of use home-manager parameter because
|
|
||||||
# of $my_pager expansion does not work as this variable is not already set
|
|
||||||
source ${config.xdg.configHome}/neomutt/${cfg.primary}
|
|
||||||
'';
|
'';
|
||||||
binds = [
|
binds = [
|
||||||
{
|
{ map = [ "attach" "browser" "index" "pager" ]; key = "g"; action = "noop"; }
|
||||||
map = ["attach" "browser" "index" "pager"];
|
{ map = [ "attach" "browser" "index" "pager" ]; key = "G"; action = "noop"; }
|
||||||
key = "g";
|
{ map = [ "index" ]; key = "q"; action = "noop";}
|
||||||
action = "noop";
|
{ map = [ "pager" ]; key = "Q"; action = "noop";}
|
||||||
}
|
{ map = [ "attach" "browser" "index" ]; key = "gg"; action = "first-entry";}
|
||||||
{
|
{ map = [ "attach" "browser" "index" ]; key = "G"; action = "last-entry";}
|
||||||
map = ["attach" "browser" "index" "pager"];
|
{ map = [ "pager" ]; key = "gg"; action = "top"; }
|
||||||
key = "G";
|
{ map = [ "pager" ]; key = "G"; action = "bottom"; }
|
||||||
action = "noop";
|
{ map = [ "pager" ]; key = "k"; action = "previous-line"; }
|
||||||
}
|
{ map = [ "pager" ]; key = "j"; action = "next-line"; }
|
||||||
{
|
|
||||||
map = ["index"];
|
|
||||||
key = "q";
|
|
||||||
action = "noop";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["pager"];
|
|
||||||
key = "Q";
|
|
||||||
action = "noop";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["attach" "browser" "index"];
|
|
||||||
key = "gg";
|
|
||||||
action = "first-entry";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["attach" "browser" "index"];
|
|
||||||
key = "G";
|
|
||||||
action = "last-entry";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["pager"];
|
|
||||||
key = "gg";
|
|
||||||
action = "top";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["pager"];
|
|
||||||
key = "G";
|
|
||||||
action = "bottom";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["pager"];
|
|
||||||
key = "k";
|
|
||||||
action = "previous-line";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["pager"];
|
|
||||||
key = "j";
|
|
||||||
action = "next-line";
|
|
||||||
}
|
|
||||||
|
|
||||||
# Scrolling
|
# Scrolling
|
||||||
{
|
{ map = [ "attach" "browser" "pager" "index" ]; key = "\\CF"; action = "next-page";}
|
||||||
map = ["attach" "browser" "pager" "index"];
|
{ map = [ "attach" "browser" "pager" "index" ]; key = "\\CB"; action = "previous-page";}
|
||||||
key = "\\CF";
|
{ map = [ "attach" "browser" "pager" "index" ]; key = "\\Cu"; action = "half-up";}
|
||||||
action = "next-page";
|
{ map = [ "attach" "browser" "pager" "index" ]; key = "\\Cd"; action = "half-down";}
|
||||||
}
|
{ map = [ "browser" "pager" ]; key = "\\Ce"; action = "next-line";}
|
||||||
{
|
{ map = [ "browser" "pager" ]; key = "\\Cy"; action = "previous-line";}
|
||||||
map = ["attach" "browser" "pager" "index"];
|
{ map = [ "index" ]; key = "\\Ce"; action = "next-line";}
|
||||||
key = "\\CB";
|
{ map = [ "index" ]; key = "\\Cy"; action = "previous-line";}
|
||||||
action = "previous-page";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["attach" "browser" "pager" "index"];
|
|
||||||
key = "\\Cu";
|
|
||||||
action = "half-up";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["attach" "browser" "pager" "index"];
|
|
||||||
key = "\\Cd";
|
|
||||||
action = "half-down";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["browser" "pager"];
|
|
||||||
key = "\\Ce";
|
|
||||||
action = "next-line";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["browser" "pager"];
|
|
||||||
key = "\\Cy";
|
|
||||||
action = "previous-line";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["index"];
|
|
||||||
key = "\\Ce";
|
|
||||||
action = "next-line";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["index"];
|
|
||||||
key = "\\Cy";
|
|
||||||
action = "previous-line";
|
|
||||||
}
|
|
||||||
|
|
||||||
# Reply
|
# Reply
|
||||||
{
|
{ map =[ "pager" "index" ]; key = "R"; action = "group-reply";}
|
||||||
map = ["pager" "index"];
|
|
||||||
key = "R";
|
|
||||||
action = "group-reply";
|
|
||||||
}
|
|
||||||
|
|
||||||
# sidebar
|
# sidebar
|
||||||
{
|
{ map = [ "index" "pager" ]; key = "<f12>"; action = "sidebar-toggle-visible";}
|
||||||
map = ["index" "pager"];
|
{ map = [ "index" "pager" ]; key = "{"; action = "sidebar-prev";}
|
||||||
key = "<f12>";
|
{ map = [ "index" "pager" ]; key = "}"; action = "sidebar-next";}
|
||||||
action = "sidebar-toggle-visible";
|
{ map = [ "index" "pager" ]; key = "|"; action = "sidebar-open";}
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["index" "pager"];
|
|
||||||
key = "{";
|
|
||||||
action = "sidebar-prev";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["index" "pager"];
|
|
||||||
key = "}";
|
|
||||||
action = "sidebar-next";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["index" "pager"];
|
|
||||||
key = "|";
|
|
||||||
action = "sidebar-open";
|
|
||||||
}
|
|
||||||
|
|
||||||
# open virtual folder
|
# open virtual folder
|
||||||
{
|
{ map = [ "index" "pager" ]; key = "X"; action = "noop";}
|
||||||
map = ["index" "pager"];
|
{ map = [ "index" "pager" ]; key = "X"; action = "change-vfolder";}
|
||||||
key = "X";
|
|
||||||
action = "noop";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["index" "pager"];
|
|
||||||
key = "X";
|
|
||||||
action = "change-vfolder";
|
|
||||||
}
|
|
||||||
|
|
||||||
# read entire thread of the current message
|
# read entire thread of the current message
|
||||||
{
|
{ map = [ "index" "pager" ]; key = "+"; action = "entire-thread";}
|
||||||
map = ["index" "pager"];
|
|
||||||
key = "+";
|
|
||||||
action = "entire-thread";
|
|
||||||
}
|
|
||||||
|
|
||||||
# generate virtual folder from query
|
# generate virtual folder from query
|
||||||
{
|
{ map = [ "index" "pager" ]; key = "\\eX"; action = "vfolder-from-query";}
|
||||||
map = ["index" "pager"];
|
|
||||||
key = "\\eX";
|
|
||||||
action = "vfolder-from-query";
|
|
||||||
}
|
|
||||||
|
|
||||||
# generate virtual folder from query with time window
|
# generate virtual folder from query with time window
|
||||||
|
|
||||||
{
|
{ map = [ "index" "pager" ]; key = "\\CD"; action = "modify-tags";}
|
||||||
map = ["index" "pager"];
|
|
||||||
key = "\\CD";
|
|
||||||
action = "modify-tags";
|
|
||||||
}
|
|
||||||
|
|
||||||
# Editor
|
# Editor
|
||||||
{
|
{ map = [ "editor" ]; key = "<Tab>"; action = "complete-query";}
|
||||||
map = ["editor"];
|
{ map = [ "editor" ]; key = "^T"; action = "complete";}
|
||||||
key = "<Tab>";
|
|
||||||
action = "complete-query";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
map = ["editor"];
|
|
||||||
key = "^T";
|
|
||||||
action = "complete";
|
|
||||||
}
|
|
||||||
];
|
];
|
||||||
macros =
|
macros = [
|
||||||
[
|
{ map = [ "pager" ]; key = "\\CB"; action = "<pipe-message>${pkgs.urlscan}/bin/urlscan -d -c --color true<Enter>"; }
|
||||||
{
|
] ++ accountMacros;
|
||||||
map = ["pager"];
|
|
||||||
key = "\\CB";
|
|
||||||
action = "<pipe-message>${pkgs.urlscan}/bin/urlscan -d -c --color true<Enter>";
|
|
||||||
}
|
|
||||||
]
|
|
||||||
++ accountMacros;
|
|
||||||
};
|
};
|
||||||
programs.mbsync = {
|
programs.mbsync = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -379,7 +234,7 @@ in {
|
||||||
};
|
};
|
||||||
programs.notmuch = {
|
programs.notmuch = {
|
||||||
enable = true;
|
enable = true;
|
||||||
new.tags = ["new"];
|
new.tags = [ "new" ];
|
||||||
hooks.postNew = ''
|
hooks.postNew = ''
|
||||||
${pkgs.afew}/bin/afew --tag --new
|
${pkgs.afew}/bin/afew --tag --new
|
||||||
${pkgs.afew}/bin/afew --move --all
|
${pkgs.afew}/bin/afew --move --all
|
||||||
|
|
|
@ -1,11 +1,9 @@
|
||||||
{
|
{ lib, config, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.application.foot;
|
cfg = config.modules.application.foot;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.application.foot = {
|
options.modules.application.foot = {
|
||||||
enable = mkEnableOption "enable Foot terminal emulator";
|
enable = mkEnableOption "enable Foot terminal emulator";
|
||||||
|
|
||||||
|
@ -67,7 +65,7 @@ in {
|
||||||
selection-foreground = "181818";
|
selection-foreground = "181818";
|
||||||
urls = "b8b8b8";
|
urls = "b8b8b8";
|
||||||
jump-labels = "181818 f7ca88";
|
jump-labels = "181818 f7ca88";
|
||||||
scrollback-indicator = "181818 b8b8b8";
|
scrollback-indicator= "181818 b8b8b8";
|
||||||
};
|
};
|
||||||
scrollback = {
|
scrollback = {
|
||||||
lines = cfg.scrollback-lines;
|
lines = cfg.scrollback-lines;
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.application.gnupg;
|
cfg = config.modules.application.gnupg;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.application.gnupg = {
|
options.modules.application.gnupg = {
|
||||||
enable = mkEnableOption "enable GnuPG and related utils";
|
enable = mkEnableOption "enable GnuPG and related utils";
|
||||||
|
|
||||||
|
@ -23,6 +20,7 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
# pinentry-gnome
|
# pinentry-gnome
|
||||||
gcr
|
gcr
|
||||||
|
@ -48,10 +46,13 @@ in {
|
||||||
noAllowExternalCache = true;
|
noAllowExternalCache = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
services.ssh-agent.enable =
|
home.sessionVariablesExtra = lib.mkIf cfg.enableSshSupport ''
|
||||||
if cfg.enableSshSupport
|
if [[ -z "''${SSH_AUTH_SOCK}" ]]; then
|
||||||
then false
|
export SSH_AUTH_SOCK="$(${config.programs.gpg.package}/bin/gpgconf --list-dirs agent-ssh-socket)"
|
||||||
else true;
|
fi
|
||||||
|
'';
|
||||||
|
|
||||||
|
services.ssh-agent.enable = if cfg.enableSshSupport then false else true;
|
||||||
programs.password-store = {
|
programs.password-store = {
|
||||||
enable = cfg.pass;
|
enable = cfg.pass;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.application.imv;
|
cfg = config.modules.application.imv;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.application.imv = {
|
options.modules.application.imv = {
|
||||||
enable = mkEnableOption "enable IMV image viewer";
|
enable = mkEnableOption "enable IMV image viewer";
|
||||||
|
|
||||||
|
@ -15,13 +12,14 @@ in {
|
||||||
default = true;
|
default = true;
|
||||||
description = "install Package, if false relies on distribution packages";
|
description = "install Package, if false relies on distribution packages";
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
programs.imv = {
|
programs.imv = {
|
||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
xdg.mimeApps.defaultApplications = {
|
xdg.mimeApps.defaultApplications = {
|
||||||
"image/*" = "imv-dir.desktop";
|
"image/*" = "imv-dir.desktop";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,11 +1,9 @@
|
||||||
{
|
{ lib, config, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.application.zathura;
|
cfg = config.modules.application.zathura;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.application.zathura = {
|
options.modules.application.zathura = {
|
||||||
enable = mkEnableOption "enable Zathura PDF viewer";
|
enable = mkEnableOption "enable Zathura PDF viewer";
|
||||||
};
|
};
|
||||||
|
@ -19,7 +17,7 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
xdg.mimeApps.defaultApplications = {
|
xdg.mimeApps.defaultApplications = {
|
||||||
"application/pdf" = "org.pwmt.zathura.desktop";
|
"application/pdf" = "org.pwmt.zathura.desktop";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,13 +1,10 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.audio.cmus;
|
cfg = config.modules.audio.cmus;
|
||||||
in {
|
in
|
||||||
options.modules.audio.cmus = {
|
{
|
||||||
|
options.modules.audio.cmus= {
|
||||||
enable = mkEnableOption "enable cmus audio player";
|
enable = mkEnableOption "enable cmus audio player";
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
|
|
@ -1,11 +1,9 @@
|
||||||
{
|
{ lib, config, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.direnv;
|
cfg = config.modules.cli.direnv;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.direnv = {
|
options.modules.cli.direnv = {
|
||||||
enable = mkEnableOption "enable direnv";
|
enable = mkEnableOption "enable direnv";
|
||||||
};
|
};
|
||||||
|
@ -14,7 +12,7 @@ in {
|
||||||
programs.direnv = {
|
programs.direnv = {
|
||||||
enable = true;
|
enable = true;
|
||||||
enableZshIntegration = true;
|
enableZshIntegration = true;
|
||||||
nix-direnv.enable = true;
|
nix-direnv.enable = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.ghq;
|
cfg = config.modules.cli.ghq;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.ghq = {
|
options.modules.cli.ghq = {
|
||||||
enable = mkEnableOption "enable ghq";
|
enable = mkEnableOption "enable ghq";
|
||||||
};
|
};
|
||||||
|
@ -21,7 +18,7 @@ in {
|
||||||
root = "~/code";
|
root = "~/code";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
home.shellAliases = {
|
home.shellAliases = {
|
||||||
# thanks jdauliac for the tip
|
# thanks jdauliac for the tip
|
||||||
g = "cd $(${pkgs.ghq}/bin/ghq root)/$(${pkgs.ghq}/bin/ghq list | ${pkgs.fzf}/bin/fzf)";
|
g = "cd $(${pkgs.ghq}/bin/ghq root)/$(${pkgs.ghq}/bin/ghq list | ${pkgs.fzf}/bin/fzf)";
|
||||||
|
|
|
@ -1,13 +1,9 @@
|
||||||
{
|
{ lib, config, pkgs, inputs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
inputs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.git;
|
cfg = config.modules.cli.git;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.git = {
|
options.modules.cli.git = {
|
||||||
enable = mkEnableOption "enable git";
|
enable = mkEnableOption "enable git";
|
||||||
|
|
||||||
|
@ -44,6 +40,7 @@ in {
|
||||||
dark = true;
|
dark = true;
|
||||||
line-numbers = true;
|
line-numbers = true;
|
||||||
syntax-theme = "base16-256";
|
syntax-theme = "base16-256";
|
||||||
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
package = pkgs.gitFull;
|
package = pkgs.gitFull;
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.k8s;
|
cfg = config.modules.cli.k8s;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.k8s = {
|
options.modules.cli.k8s = {
|
||||||
enable = mkEnableOption "Install k8s utils";
|
enable = mkEnableOption "Install k8s utils";
|
||||||
|
|
||||||
|
@ -18,12 +15,10 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
home.packages = with pkgs;
|
home.packages = with pkgs; [
|
||||||
[
|
kubectl
|
||||||
kubectl
|
kubecm
|
||||||
kubecm
|
] ++ cfg.kubectlPlugins;
|
||||||
]
|
|
||||||
++ cfg.kubectlPlugins;
|
|
||||||
programs.k9s = {
|
programs.k9s = {
|
||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,10 +1,6 @@
|
||||||
{
|
{ lib, pkgs, config, ... }:
|
||||||
lib,
|
with lib;
|
||||||
pkgs,
|
let
|
||||||
config,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.neovim;
|
cfg = config.modules.cli.neovim;
|
||||||
nvim-spell-fr-utf8-dictionary = builtins.fetchurl {
|
nvim-spell-fr-utf8-dictionary = builtins.fetchurl {
|
||||||
url = "https://ftp.nluug.nl/vim/runtime/spell/fr.utf-8.spl";
|
url = "https://ftp.nluug.nl/vim/runtime/spell/fr.utf-8.spl";
|
||||||
|
@ -18,38 +14,37 @@ with lib; let
|
||||||
## Dynamically create LSP servers configurations list regarding
|
## Dynamically create LSP servers configurations list regarding
|
||||||
## files in `./files/lsp`
|
## files in `./files/lsp`
|
||||||
lspConfigFiles = lib.mapAttrs' (
|
lspConfigFiles = lib.mapAttrs' (
|
||||||
k: _:
|
k: _: lib.nameValuePair
|
||||||
lib.nameValuePair
|
("${config.xdg.configHome}/nvim/lsp/${k}")
|
||||||
"${config.xdg.configHome}/nvim/lsp/${k}"
|
({ source = ./files/lsp/${k};})
|
||||||
{source = ./files/lsp/${k};}
|
) (builtins.readDir ./files/lsp);
|
||||||
) (builtins.readDir ./files/lsp);
|
|
||||||
|
|
||||||
## This variable contains neovim LSP activations
|
## This variable contains neovim LSP activations
|
||||||
lspLuaConfig = lib.attrsets.mapAttrsToList (
|
lspLuaConfig = lib.attrsets.mapAttrsToList (
|
||||||
k: v: "vim.lsp.enable('${lib.removeSuffix ".lua" k}')"
|
k: v:
|
||||||
|
"vim.lsp.enable('${lib.removeSuffix ".lua" k}')"
|
||||||
) (builtins.readDir ./files/lsp);
|
) (builtins.readDir ./files/lsp);
|
||||||
|
|
||||||
## Tony plugins to have a proper helm linting.
|
## Tony plugins to have a proper helm linting.
|
||||||
nvim-k8s-lsp = pkgs.vimUtils.buildVimPlugin {
|
nvim-k8s-lsp = pkgs.vimUtils.buildVimPlugin {
|
||||||
pname = "nvim-k8s-lsp";
|
pname = "nvim-k8s-lsp";
|
||||||
version = "main";
|
version = "main";
|
||||||
src = builtins.fetchGit {
|
src = builtins.fetchGit {
|
||||||
url = "https://github.com/tonychg/nvim-k8s-lsp.git";
|
url = "https://github.com/tonychg/nvim-k8s-lsp.git";
|
||||||
rev = "1dffda65f4fe117f67514ed5d93b18f62be1ef24";
|
rev = "930aa20bcd54f2d6f16040e98ff4068b292c6c7f";
|
||||||
ref = "main";
|
ref = "main";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.neovim = {
|
options.modules.cli.neovim = {
|
||||||
enable = mkEnableOption "enable Neovim text editor";
|
enable = mkEnableOption "enable Neovim text editor";
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
home.file =
|
home.file = lspConfigFiles // {
|
||||||
lspConfigFiles
|
"${config.xdg.configHome}/nvim/spell/fr.utf-8.spl".source = nvim-spell-fr-utf8-dictionary;
|
||||||
// {
|
"${config.xdg.configHome}/nvim/spell/fr.utf-8.sug".source = nvim-spell-fr-utf8-suggestions;
|
||||||
"${config.xdg.configHome}/nvim/spell/fr.utf-8.spl".source = nvim-spell-fr-utf8-dictionary;
|
};
|
||||||
"${config.xdg.configHome}/nvim/spell/fr.utf-8.sug".source = nvim-spell-fr-utf8-suggestions;
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.neovim = {
|
programs.neovim = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -70,13 +65,13 @@ in {
|
||||||
python3Packages.python-lsp-server
|
python3Packages.python-lsp-server
|
||||||
shellcheck
|
shellcheck
|
||||||
|
|
||||||
tofu-ls
|
terraform-lsp
|
||||||
tflint
|
tflint
|
||||||
vscode-langservers-extracted
|
vscode-langservers-extracted
|
||||||
yaml-language-server
|
yaml-language-server
|
||||||
|
|
||||||
# Formatters
|
# Formatters
|
||||||
alejandra
|
nixfmt-rfc-style
|
||||||
shfmt
|
shfmt
|
||||||
yamlfmt
|
yamlfmt
|
||||||
];
|
];
|
||||||
|
@ -84,8 +79,9 @@ in {
|
||||||
(builtins.readFile ./files/options.lua)
|
(builtins.readFile ./files/options.lua)
|
||||||
+ (builtins.readFile ./files/keybindings.lua)
|
+ (builtins.readFile ./files/keybindings.lua)
|
||||||
+ ''
|
+ ''
|
||||||
${lib.concatStringsSep "\n" lspLuaConfig}
|
${ lib.concatStringsSep "\n" lspLuaConfig}
|
||||||
'';
|
''
|
||||||
|
;
|
||||||
plugins = with pkgs.vimPlugins; [
|
plugins = with pkgs.vimPlugins; [
|
||||||
{
|
{
|
||||||
plugin = nvim-autopairs;
|
plugin = nvim-autopairs;
|
||||||
|
@ -97,39 +93,39 @@ in {
|
||||||
{
|
{
|
||||||
plugin = catppuccin-nvim;
|
plugin = catppuccin-nvim;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = builtins.readFile ./files/plugins/theme.lua;
|
config = (builtins.readFile ./files/plugins/theme.lua);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = blink-cmp;
|
plugin = blink-cmp;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = builtins.readFile ./files/plugins/blink-cmp.lua;
|
config = (builtins.readFile ./files/plugins/blink-cmp.lua);
|
||||||
}
|
}
|
||||||
blink-emoji-nvim
|
blink-emoji-nvim
|
||||||
blink-cmp-dictionary
|
blink-cmp-dictionary
|
||||||
{
|
{
|
||||||
plugin = conform-nvim;
|
plugin = conform-nvim;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = builtins.readFile ./files/plugins/conform.lua;
|
config = (builtins.readFile ./files/plugins/conform.lua);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = dropbar-nvim;
|
plugin = dropbar-nvim;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = builtins.readFile ./files/plugins/dropbar.lua;
|
config = (builtins.readFile ./files/plugins/dropbar.lua);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = fzf-lua;
|
plugin = fzf-lua;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = builtins.readFile ./files/plugins/fzf-lua.lua;
|
config = (builtins.readFile ./files/plugins/fzf-lua.lua);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = gitsigns-nvim;
|
plugin = gitsigns-nvim;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = builtins.readFile ./files/plugins/gitsign.lua;
|
config = (builtins.readFile ./files/plugins/luasnip.lua);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = indent-blankline-nvim;
|
plugin = indent-blankline-nvim;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = ''
|
config =''
|
||||||
require("ibl").setup{
|
require("ibl").setup{
|
||||||
indent = { char = "│"},
|
indent = { char = "│"},
|
||||||
}
|
}
|
||||||
|
@ -138,41 +134,39 @@ in {
|
||||||
{
|
{
|
||||||
plugin = lualine-nvim;
|
plugin = lualine-nvim;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = builtins.readFile ./files/plugins/lualine.lua;
|
config = (builtins.readFile ./files/plugins/lualine.lua);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = neo-tree-nvim;
|
plugin = neo-tree-nvim;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = builtins.readFile ./files/plugins/neotree.lua;
|
config = (builtins.readFile ./files/plugins/neotree.lua);
|
||||||
}
|
}
|
||||||
nui-nvim
|
nui-nvim
|
||||||
{
|
{
|
||||||
plugin = nvim-web-devicons;
|
plugin = nvim-web-devicons;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = ''
|
config=''
|
||||||
require('nvim-web-devicons').setup {}
|
require('nvim-web-devicons').setup {}
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = nvim-lint;
|
plugin = nvim-lint;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = (builtins.readFile ./files/plugins/nvim-lint.lua);
|
config = ( builtins.readFile ./files/plugins/nvim-lint.lua);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = nvim-sops;
|
plugin = nvim-sops;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = builtins.readFile ./files/plugins/nvim-sops.lua;
|
config = (builtins.readFile ./files/plugins/nvim-sops.lua);
|
||||||
}
|
}
|
||||||
plenary-nvim
|
plenary-nvim
|
||||||
{
|
{
|
||||||
plugin = (
|
plugin = (nvim-treesitter.withPlugins (p: [
|
||||||
nvim-treesitter.withPlugins (p: [
|
|
||||||
p.bash
|
p.bash
|
||||||
p.c
|
p.c
|
||||||
p.cpp
|
p.cpp
|
||||||
p.cmake
|
p.cmake
|
||||||
p.dockerfile
|
p.dockerfile
|
||||||
p.go
|
|
||||||
p.hcl
|
p.hcl
|
||||||
p.helm
|
p.helm
|
||||||
p.javascript
|
p.javascript
|
||||||
|
@ -192,27 +186,25 @@ in {
|
||||||
])
|
])
|
||||||
);
|
);
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = (builtins.readFile ./files/plugins/treesitter.lua);
|
config = ( builtins.readFile ./files/plugins/treesitter.lua);
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = nvim-treesitter-context;
|
plugin = nvim-treesitter-context;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = (builtins.readFile ./files/plugins/treesitter_context.lua);
|
config = ( builtins.readFile ./files/plugins/treesitter_context.lua);
|
||||||
|
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = which-key-nvim;
|
plugin = which-key-nvim;
|
||||||
type = "lua";
|
type = "lua";
|
||||||
config = (builtins.readFile ./files/plugins/whichkey.lua);
|
config = ( builtins.readFile ./files/plugins/whichkey.lua );
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
plugin = nvim-k8s-lsp;
|
plugin = nvim-k8s-lsp ;
|
||||||
type = "lua";
|
|
||||||
config = (builtins.readFile ./files/plugins/nvim-k8s-lsp.lua);
|
|
||||||
}
|
|
||||||
{
|
|
||||||
plugin = helm-ls-nvim;
|
|
||||||
type = "lua";
|
type = "lua";
|
||||||
|
config = ( builtins.readFile ./files/plugins/nvim-k8s-lsp.lua );
|
||||||
}
|
}
|
||||||
|
vim-helm
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,15 +1,6 @@
|
||||||
local opts = { noremap = true, silent = true}
|
|
||||||
|
|
||||||
vim.api.nvim_set_keymap('n', '<leader>/', ':nohlsearch<CR>', opts)
|
|
||||||
vim.api.nvim_set_keymap('n', '<leader>l', ':set list!<CR>', {silent = true})
|
|
||||||
|
|
||||||
-- clear search
|
-- clear search
|
||||||
vim.keymap.set('n', '<leader>l', ':nohlsearch<CR>', { desc = 'Clear search', remap = true, silent = true })
|
vim.keymap.set('n', '<leader>l', ':nohlsearch<CR>', { desc = 'Clear search', remap = true, silent = true })
|
||||||
|
|
||||||
-- Move tabs with \[ and \]
|
|
||||||
vim.api.nvim_set_keymap('n', '<Leader>]', ':tabnext<CR>', opts)
|
|
||||||
vim.api.nvim_set_keymap('n', '<Leader>[', ':tabprev<CR>', opts)
|
|
||||||
|
|
||||||
-- Switch between windows.
|
-- Switch between windows.
|
||||||
vim.keymap.set('n', '<C-h>', '<C-w>h', { desc = 'Move to the left window', remap = true })
|
vim.keymap.set('n', '<C-h>', '<C-w>h', { desc = 'Move to the left window', remap = true })
|
||||||
vim.keymap.set('n', '<C-j>', '<C-w>j', { desc = 'Move to the bottom window', remap = true })
|
vim.keymap.set('n', '<C-j>', '<C-w>j', { desc = 'Move to the bottom window', remap = true })
|
||||||
|
@ -28,3 +19,31 @@ vim.keymap.set('n', '<Leader>tn', ':tabnew<CR>', { desc = "Tab [n]ew", remap = t
|
||||||
|
|
||||||
-- Show all caracters
|
-- Show all caracters
|
||||||
vim.keymap.set('n', '<leader>l', ':set list!<CR>', { desc = "Show a[l]l caraters", remap = true, silent = true})
|
vim.keymap.set('n', '<leader>l', ':set list!<CR>', { desc = "Show a[l]l caraters", remap = true, silent = true})
|
||||||
|
|
||||||
|
-- neotree
|
||||||
|
-- -------
|
||||||
|
vim.keymap.set('n', '<leader>nc', ':Neotree close<cr>', {desc='Neotree [c]lose'})
|
||||||
|
vim.keymap.set('n', '<leader>nf', ':Neotree focus filesystem<cr>', {desc='Neotree [f]ocus'})
|
||||||
|
vim.keymap.set('n', '<leader>nb', ':Neotree focus buffers<cr>', {desc='Neotree Nvim [b]uffers'})
|
||||||
|
vim.keymap.set('n', '<leader>ng', ':Neotree focus git_status<cr>', {desc='Neotree [g]it status'})
|
||||||
|
|
||||||
|
-- fzf-lua
|
||||||
|
-- ------
|
||||||
|
vim.keymap.set('n', '<leader>fb', function() require('fzf-lua').buffers() end, {desc='open [b]uffers'})
|
||||||
|
vim.keymap.set('n', '<leader>ff', function() require('fzf-lua').files() end, {desc='[r]esume last command'})
|
||||||
|
vim.keymap.set('n', '<leader>fr', function() require('fzf-lua').files() end, {desc='[f]iles'})
|
||||||
|
|
||||||
|
-- git related keymaps
|
||||||
|
vim.keymap.set('n', '<leader>fgb', function() require('fzf-lua').git_branches() end, {desc='Git [b]ranches'})
|
||||||
|
vim.keymap.set('n', '<leader>fgc', function() require('fzf-lua').git_commits() end, {desc='Git [c]ommits'})
|
||||||
|
vim.keymap.set('n', '<leader>fgC', function() require('fzf-lua').git_bcommits() end, {desc='Git current buffer [C]ommits'})
|
||||||
|
vim.keymap.set('n', '<leader>fgf', function() require('fzf-lua').git_files() end, {desc='Git [f]iles'})
|
||||||
|
vim.keymap.set('n', '<leader>fgs', function() require('fzf-lua').git_stash() end, {desc='Git [s]tash'})
|
||||||
|
vim.keymap.set('n', '<leader>fgS', function() require('fzf-lua').git_status() end, {desc='Git [S]tash'})
|
||||||
|
|
||||||
|
-- grep related keymaps
|
||||||
|
vim.keymap.set('n', '<leader>fGb', function() require('fzf-lua').grep_curbuf() end, {desc='grep in current [b]uffer'})
|
||||||
|
vim.keymap.set('n', '<leader>fGc', function() require('fzf-lua').grep_cword() end, {desc='grep word under the [c]ursor'})
|
||||||
|
vim.keymap.set('n', '<leader>fGg', function() require('fzf-lua').grep() end, {desc='[g]rep'})
|
||||||
|
vim.keymap.set('n', '<leader>fGl', function() require('fzf-lua').live_grep() end, {desc='[l]ive grep'})
|
||||||
|
vim.keymap.set('n', '<leader>fGr', function() require('fzf-lua').grep_last() end, {desc='[r]erun last grep'})
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
return {
|
return {
|
||||||
cmd = { 'helm_ls', 'serve' },
|
cmd = { 'helm_ls', 'serve' },
|
||||||
filetypes = { 'helm', 'yaml.helm-values' },
|
filetypes = { 'helm' },
|
||||||
single_file_support = true,
|
root_markers = { 'Chart.yaml' },
|
||||||
root_markers = { 'values.yaml', 'Chart.yaml' },
|
|
||||||
capabilities = {
|
capabilities = {
|
||||||
workspace = {
|
workspace = {
|
||||||
didChangeWatchedFiles = {
|
didChangeWatchedFiles = {
|
||||||
|
@ -19,7 +18,9 @@ return {
|
||||||
showdiagnosticsdirectly = false,
|
showdiagnosticsdirectly = false,
|
||||||
path = "yaml-language-server",
|
path = "yaml-language-server",
|
||||||
config = {
|
config = {
|
||||||
schemas = {},
|
schemas = {
|
||||||
|
kubernetes = "template/**",
|
||||||
|
},
|
||||||
completion = true,
|
completion = true,
|
||||||
hover = true,
|
hover = true,
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
return {
|
return {
|
||||||
cmd = { 'tofu-ls', 'serve' },
|
cmd = { 'terraform-ls', 'serve' },
|
||||||
filetypes = { 'terraform', 'terraform-vars' },
|
filetypes = { 'terraform', 'terraform-vars' },
|
||||||
root_markers = { '.terraform', '.git' },
|
root_markers = { '.terraform', '.git' },
|
||||||
}
|
}
|
|
@ -52,7 +52,7 @@ vim.opt.wildmode = 'lastused:full,list' -- enhance menu
|
||||||
vim.opt.pumheight = 10
|
vim.opt.pumheight = 10
|
||||||
vim.opt.pumwidth = 50
|
vim.opt.pumwidth = 50
|
||||||
vim.opt.pumblend = 10
|
vim.opt.pumblend = 10
|
||||||
vim.o.winborder = 'none'
|
|
||||||
-- manage line break smartly
|
-- manage line break smartly
|
||||||
vim.opt.wrap = true
|
vim.opt.wrap = true
|
||||||
vim.opt.breakindent = true
|
vim.opt.breakindent = true
|
||||||
|
@ -103,13 +103,24 @@ vim.opt.wildignore = {
|
||||||
'*.sw?'
|
'*.sw?'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
-- Key biding
|
||||||
|
-- " ----------
|
||||||
|
local opts = { noremap = true, silent = true}
|
||||||
|
|
||||||
|
vim.api.nvim_set_keymap('n', '<leader>/', ':nohlsearch<CR>', opts)
|
||||||
|
|
||||||
|
-- Move tabs with \[ and \]
|
||||||
|
vim.api.nvim_set_keymap('n', '<Leader>]', ':tabnext<CR>', opts)
|
||||||
|
vim.api.nvim_set_keymap('n', '<Leader>[', ':tabprev<CR>', opts)
|
||||||
|
vim.api.nvim_set_keymap('n', '<leader>l', ':set list!<CR>', {silent = true})
|
||||||
|
|
||||||
-- disable lsplog
|
-- disable lsplog
|
||||||
-- This is not usefull on a daily basis and should positively impact performance
|
-- This is not usefull on a daily basis and should positively impact performance
|
||||||
vim.lsp.set_log_level("off")
|
vim.lsp.set_log_level("off")
|
||||||
|
|
||||||
-- define a timeout for match parens
|
-- define a timeout for match parens
|
||||||
vim.g.matchparen_timeout = 10
|
vim.g.matchparen_timeout = 2
|
||||||
vim.g.matchparen_insert_timeout = 10
|
vim.g.matchparen_insert_timeout = 2
|
||||||
|
|
||||||
-- activate virtual lines for diagnistics
|
-- activate virtual lines for diagnistics
|
||||||
-- no more plugins needed
|
-- no more plugins needed
|
||||||
|
@ -123,73 +134,3 @@ vim.diagnostic.config({
|
||||||
-- },
|
-- },
|
||||||
signs = { text = { [x.ERROR] = "", [x.WARN] = "", [x.INFO] = "", [x.HINT] = "" } },
|
signs = { text = { [x.ERROR] = "", [x.WARN] = "", [x.INFO] = "", [x.HINT] = "" } },
|
||||||
})
|
})
|
||||||
|
|
||||||
-- LSP
|
|
||||||
vim.api.nvim_create_autocmd("LspAttach", {
|
|
||||||
group = vim.api.nvim_create_augroup("UserLspConfig", {}),
|
|
||||||
callback = function(ev)
|
|
||||||
vim.bo[ev.buf].omnifunc = "v:lua.vim.lsp.omnifunc"
|
|
||||||
|
|
||||||
local opts = { buffer = ev.buf }
|
|
||||||
local client = vim.lsp.get_client_by_id(ev.data.client_id)
|
|
||||||
local bufnr = ev.buf
|
|
||||||
local function desc(description)
|
|
||||||
return { noremap = true, silent = true, buffer = bufnr, desc = description }
|
|
||||||
end
|
|
||||||
|
|
||||||
vim.keymap.set("n", "gD", vim.lsp.buf.declaration, { buffer = ev.buf, desc = "Go to [D]eclaration" })
|
|
||||||
vim.keymap.set("n", "gd", vim.lsp.buf.definition, { buffer = ev.buf, desc = "Go to [d]efinition" })
|
|
||||||
vim.keymap.set("n", "gi", vim.lsp.buf.implementation, { buffer = ev.buf, desc = "Go to [i]mplementation" })
|
|
||||||
vim.keymap.set("n", "gr", vim.lsp.buf.references, { buffer = ev.buf, desc = "Go to [r]eferences" })
|
|
||||||
|
|
||||||
vim.keymap.set(
|
|
||||||
"n",
|
|
||||||
"K",
|
|
||||||
function()
|
|
||||||
vim.lsp.buf.hover
|
|
||||||
{ border = "rounded", max_width = 250 }
|
|
||||||
end,
|
|
||||||
opts)
|
|
||||||
|
|
||||||
vim.keymap.set(
|
|
||||||
"n",
|
|
||||||
"<C-k>",
|
|
||||||
function()
|
|
||||||
vim.lsp.buf.signature_help
|
|
||||||
{ border = "rounded", max_width = 250 }
|
|
||||||
end,
|
|
||||||
{buffer = ev.buf, desc = "Signature help"}
|
|
||||||
)
|
|
||||||
|
|
||||||
vim.keymap.set("n", "<leader>wa", vim.lsp.buf.add_workspace_folder, opts)
|
|
||||||
vim.keymap.set("n", "<leader>wr", vim.lsp.buf.remove_workspace_folder, opts)
|
|
||||||
|
|
||||||
vim.keymap.set(
|
|
||||||
"n",
|
|
||||||
"<leader>wl",
|
|
||||||
function()
|
|
||||||
print(vim.inspect(vim.lsp.buf.list_workspace_folders()))
|
|
||||||
end,
|
|
||||||
opts
|
|
||||||
)
|
|
||||||
|
|
||||||
vim.keymap.set("n", "<leader>D", vim.lsp.buf.type_definition, { buffer = ev.buf, desc = "Type [D]efinition" })
|
|
||||||
vim.keymap.set("n", "<leader>rn", vim.lsp.buf.rename, { buffer = ev.buf, desc = "LSP [r]e[n]ame" })
|
|
||||||
vim.keymap.set("n", "<leader>ca", vim.lsp.buf.code_action, { buffer = ev.buf, desc = "Show [c]ode [a]ction"})
|
|
||||||
|
|
||||||
vim.keymap.set(
|
|
||||||
"n",
|
|
||||||
"<leader>F",
|
|
||||||
function()
|
|
||||||
require("conform").format({ bufnr = bufnr })
|
|
||||||
end,
|
|
||||||
{ buffer = ev.buf, desc = "[F]ormat file" }
|
|
||||||
)
|
|
||||||
|
|
||||||
if client.server_capabilities.inlayHintProvider then
|
|
||||||
vim.keymap.set("n", "<space>h", function()
|
|
||||||
vim.lsp.inlay_hint.enable(not vim.lsp.inlay_hint.is_enabled())
|
|
||||||
end, desc("LSP toggle inlay [h]ints"))
|
|
||||||
end
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
|
|
|
@ -4,20 +4,10 @@ require("conform").setup({
|
||||||
timeout_ms = 500,
|
timeout_ms = 500,
|
||||||
lsp_format = "never",
|
lsp_format = "never",
|
||||||
},
|
},
|
||||||
formatters = {
|
|
||||||
terraform = {
|
|
||||||
inherit = false,
|
|
||||||
command = "tofu",
|
|
||||||
args = { "fmt", "-" },
|
|
||||||
stdin = true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
formatters_by_ft = {
|
formatters_by_ft = {
|
||||||
go = { "gofmt" },
|
|
||||||
nix = { "alejandra" },
|
|
||||||
sh = { "shfmt" },
|
|
||||||
terraform = { "terraform" },
|
|
||||||
yaml = {"yamlfmt"},
|
yaml = {"yamlfmt"},
|
||||||
|
sh = { "shfmt" },
|
||||||
|
go = { "gofmt" },
|
||||||
["_"] = { "trim_whitespace" },
|
["_"] = { "trim_whitespace" },
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -18,8 +18,3 @@ neotree.setup({
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
vim.keymap.set('n', '<leader>nc', ':Neotree close<cr>', {desc='Neotree [c]lose'})
|
|
||||||
vim.keymap.set('n', '<leader>nf', ':Neotree focus filesystem<cr>', {desc='Neotree [f]ocus'})
|
|
||||||
vim.keymap.set('n', '<leader>nb', ':Neotree focus buffers<cr>', {desc='Neotree Nvim [b]uffers'})
|
|
||||||
vim.keymap.set('n', '<leader>ng', ':Neotree focus git_status<cr>', {desc='Neotree [g]it status'})
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
require("nvim-k8s-lsp").setup({
|
require("nvim-k8s-lsp").setup({
|
||||||
kubernetes_version = "v1.32.8",
|
kubernetes_version = "v1.32.2",
|
||||||
integrations = {
|
integrations = {
|
||||||
lualine = true,
|
lualine = false,
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -1,11 +1,9 @@
|
||||||
{
|
{ lib, config, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.starship;
|
cfg = config.modules.cli.starship;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.starship = {
|
options.modules.cli.starship = {
|
||||||
enable = mkEnableOption "enable starship prompt";
|
enable = mkEnableOption "enable starship prompt";
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,13 +1,10 @@
|
||||||
{
|
|
||||||
lib,
|
{ lib, config, pkgs, inputs, ... }:
|
||||||
config,
|
with lib;
|
||||||
pkgs,
|
let
|
||||||
inputs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.tmux;
|
cfg = config.modules.cli.tmux;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.tmux = {
|
options.modules.cli.tmux = {
|
||||||
enable = mkEnableOption "enable Tmux";
|
enable = mkEnableOption "enable Tmux";
|
||||||
extraConfig = mkOption {
|
extraConfig = mkOption {
|
||||||
|
@ -32,64 +29,63 @@ in {
|
||||||
mouse = true;
|
mouse = true;
|
||||||
prefix = "C-a";
|
prefix = "C-a";
|
||||||
terminal = "tmux-256color";
|
terminal = "tmux-256color";
|
||||||
extraConfig =
|
extraConfig = ''
|
||||||
''
|
set -g detach-on-destroy off
|
||||||
set -g detach-on-destroy off
|
set -g display-time 1500
|
||||||
set -g display-time 1500
|
|
||||||
|
|
||||||
bind -n -N "Select pane to the left of the active pane" M-h select-pane -L
|
bind -n -N "Select pane to the left of the active pane" M-h select-pane -L
|
||||||
bind -n -N "Select pane below the active pane" M-j select-pane -D
|
bind -n -N "Select pane below the active pane" M-j select-pane -D
|
||||||
bind -n -N "Select pane above the active pane" M-k select-pane -U
|
bind -n -N "Select pane above the active pane" M-k select-pane -U
|
||||||
bind -n -N "Select pane to the right of the active pane" M-l select-pane -R
|
bind -n -N "Select pane to the right of the active pane" M-l select-pane -R
|
||||||
|
|
||||||
bind -n -r -N "Resize the pane left by 5" M-H resize-pane -L 5
|
bind -n -r -N "Resize the pane left by 5" M-H resize-pane -L 5
|
||||||
bind -n -r -N "Resize the pane down by 5" M-J resize-pane -D 5
|
bind -n -r -N "Resize the pane down by 5" M-J resize-pane -D 5
|
||||||
bind -n -r -N "Resize the pane up by 5" M-K resize-pane -U 5
|
bind -n -r -N "Resize the pane up by 5" M-K resize-pane -U 5
|
||||||
bind -n -r -N "Resize the pane right by 5" M-L resize-pane -R 5
|
bind -n -r -N "Resize the pane right by 5" M-L resize-pane -R 5
|
||||||
bind -n M-n split-window -h -c "#{pane_current_path}"
|
bind -n M-n split-window -h -c "#{pane_current_path}"
|
||||||
bind -n M-N split-window -v -c "#{pane_current_path}"
|
bind -n M-N split-window -v -c "#{pane_current_path}"
|
||||||
|
|
||||||
# define sessions with Alt+F{1..4} for general purpose sessions
|
# define sessions with Alt+F{1..4} for general purpose sessions
|
||||||
bind -n M-F1 if 'tmux has-session -t 1' {switch-client -t 1} {display-popup -E -E 'create-tmux-session -i 1'}
|
bind -n M-F1 if 'tmux has-session -t 1' {switch-client -t 1} {display-popup -E -E 'create-tmux-session -i 1'}
|
||||||
bind -n M-F2 if 'tmux has-session -t 2' {switch-client -t 2} {display-popup -E -E 'create-tmux-session -i 2'}
|
bind -n M-F2 if 'tmux has-session -t 2' {switch-client -t 2} {display-popup -E -E 'create-tmux-session -i 2'}
|
||||||
bind -n M-F3 if 'tmux has-session -t 3' {switch-client -t 3} {display-popup -E -E 'create-tmux-session -i 3'}
|
bind -n M-F3 if 'tmux has-session -t 3' {switch-client -t 3} {display-popup -E -E 'create-tmux-session -i 3'}
|
||||||
bind -n M-F4 if 'tmux has-session -t 4' {switch-client -t 4} {display-popup -E -E 'create-tmux-session -i 4'}
|
bind -n M-F4 if 'tmux has-session -t 4' {switch-client -t 4} {display-popup -E -E 'create-tmux-session -i 4'}
|
||||||
|
|
||||||
# change window with Alt+{1..5}
|
# change window with Alt+{1..5}
|
||||||
bind -n -N "Goto window 1" M-1 select-window -T -t 1
|
bind -n -N "Goto window 1" M-1 select-window -T -t 1
|
||||||
bind -n -N "Goto window 2" M-2 select-window -T -t 2
|
bind -n -N "Goto window 2" M-2 select-window -T -t 2
|
||||||
bind -n -N "Goto window 3" M-3 select-window -T -t 3
|
bind -n -N "Goto window 3" M-3 select-window -T -t 3
|
||||||
bind -n -N "Goto window 4" M-4 select-window -T -t 4
|
bind -n -N "Goto window 4" M-4 select-window -T -t 4
|
||||||
bind -n -N "Goto window 5" M-5 select-window -T -t 5
|
bind -n -N "Goto window 5" M-5 select-window -T -t 5
|
||||||
|
|
||||||
# Theme
|
# Theme
|
||||||
set -g status-interval 2
|
set -g status-interval 2
|
||||||
setw -g automatic-rename on # rename window to reflect current program
|
setw -g automatic-rename on # rename window to reflect current program
|
||||||
set -g renumber-windows on # renumber windows when a window is closed
|
set -g renumber-windows on # renumber windows when a window is closed
|
||||||
set -g set-titles on
|
set -g set-titles on
|
||||||
set -g mode-style bg=colour18,fg=colour7
|
set -g mode-style bg=colour18,fg=colour7
|
||||||
set -g set-titles-string "#T"
|
set -g set-titles-string "#T"
|
||||||
set -g status-bg colour0
|
set -g status-bg colour0
|
||||||
set -g status-fg colour7
|
set -g status-fg colour7
|
||||||
set -g message-style bg=colour19,fg=colour7
|
set -g message-style bg=colour19,fg=colour7
|
||||||
|
|
||||||
setw -g window-status-current-format '#[fg=colour18,bg=colour11] #I\
|
setw -g window-status-current-format '#[fg=colour18,bg=colour11] #I\
|
||||||
#[bg=colour19,fg=colour7,bold] #W\
|
#[bg=colour19,fg=colour7,bold] #W\
|
||||||
#{?window_active, ,}#{?window_marked_flag, ,}#{?window_activity_flag, ,}#{?window_silence_flag, ,}#{?window_zoomed_flag, ,}'
|
#{?window_active, ,}#{?window_marked_flag, ,}#{?window_activity_flag, ,}#{?window_silence_flag, ,}#{?window_zoomed_flag, ,}'
|
||||||
|
|
||||||
set -g pane-border-style fg=colour19
|
set -g pane-border-style fg=colour19
|
||||||
set -g pane-active-border-style fg=colour4
|
set -g pane-active-border-style fg=colour4
|
||||||
|
|
||||||
setw -g window-status-format '#[bg=color12,fg=colour19] #I\
|
setw -g window-status-format '#[bg=color12,fg=colour19] #I\
|
||||||
#[bg=colour18,fg=colour7,dim] #W\
|
#[bg=colour18,fg=colour7,dim] #W\
|
||||||
#{?window_last_flag, ,}#{?window_marked_flag, ,}#{?window_activity_flag, ,}#{?window_silence_flag, ,}#{?window_zoomed_flag, ,}#{?window_bell_flag,#[bg=colour1]#[fg=colour15]#[none] ,}'
|
#{?window_last_flag, ,}#{?window_marked_flag, ,}#{?window_activity_flag, ,}#{?window_silence_flag, ,}#{?window_zoomed_flag, ,}#{?window_bell_flag,#[bg=colour1]#[fg=colour15]#[none] ,}'
|
||||||
setw -g window-status-bell-style bg=colour18,fg=colour7
|
setw -g window-status-bell-style bg=colour18,fg=colour7
|
||||||
set -g status-left-length 100
|
set -g status-left-length 100
|
||||||
set -g status-left '#[bg=colour0, fg=colour6] #S '
|
set -g status-left '#[bg=colour0, fg=colour6] #S '
|
||||||
set -g status-right ' '
|
set -g status-right ' '
|
||||||
''
|
''
|
||||||
+ inputs.nix-private.tmux.nix
|
+ inputs.nix-private.tmux.nix
|
||||||
+ cfg.extraConfig;
|
+ cfg.extraConfig;
|
||||||
plugins = with pkgs; [
|
plugins = with pkgs; [
|
||||||
tmuxPlugins.tmux-fzf
|
tmuxPlugins.tmux-fzf
|
||||||
];
|
];
|
||||||
|
|
|
@ -162,7 +162,7 @@ tmux_vsplit() {
|
||||||
tmux_hsplit() {
|
tmux_hsplit() {
|
||||||
local size="${1:-20}"
|
local size="${1:-20}"
|
||||||
debug "execute hsplit with size '${size}'"
|
debug "execute hsplit with size '${size}'"
|
||||||
tmux split-window -t "${SESSION_NAME}" -c "$CURRENT_PATH" -h -p "$size"
|
tmux split-window "${SESSION_NAME}" -c "$CURRENT_PATH" -h -p "$size"
|
||||||
}
|
}
|
||||||
|
|
||||||
tmux_neww() {
|
tmux_neww() {
|
||||||
|
|
|
@ -1,16 +1,14 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.utils;
|
cfg = config.modules.cli.utils;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.utils = {
|
options.modules.cli.utils = {
|
||||||
enable = mkEnableOption "Install cli utils";
|
enable = mkEnableOption "Install cli utils";
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
|
||||||
programs.bat = {
|
programs.bat = {
|
||||||
enable = true;
|
enable = true;
|
||||||
config = {
|
config = {
|
||||||
|
@ -23,6 +21,7 @@ in {
|
||||||
};
|
};
|
||||||
programs.fd = {
|
programs.fd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
||||||
};
|
};
|
||||||
programs.fzf = {
|
programs.fzf = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
|
|
@ -1,19 +1,16 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.vifm;
|
cfg = config.modules.cli.vifm;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.vifm = {
|
options.modules.cli.vifm = {
|
||||||
enable = mkEnableOption "enable Vifm file browser";
|
enable = mkEnableOption "enable Vifm file browser";
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
vifm
|
vifm
|
||||||
chafa # Preview images
|
chafa # Preview images
|
||||||
poppler_utils # Preview PDF file
|
poppler_utils # Preview PDF file
|
||||||
];
|
];
|
||||||
programs.zsh = {
|
programs.zsh = {
|
||||||
|
|
|
@ -1,11 +1,9 @@
|
||||||
{
|
{ lib, config, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.zellij;
|
cfg = config.modules.cli.zellij;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.zellij = {
|
options.modules.cli.zellij = {
|
||||||
enable = mkEnableOption "enable Zellij";
|
enable = mkEnableOption "enable Zellij";
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,26 +1,23 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.cli.zsh;
|
cfg = config.modules.cli.zsh;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.cli.zsh = {
|
options.modules.cli.zsh = {
|
||||||
enable = mkEnableOption "enable Zsh configuration";
|
enable = mkEnableOption "enable Zsh configuration";
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
programs.zsh = {
|
programs.zsh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
dotDir = "${config.xdg.configHome}/zsh";
|
dotDir = ".config/zsh";
|
||||||
defaultKeymap = "viins";
|
defaultKeymap = "viins";
|
||||||
enableCompletion = true;
|
enableCompletion = true;
|
||||||
history = {
|
history = {
|
||||||
ignoreAllDups = true;
|
ignoreAllDups = true;
|
||||||
save = 10000;
|
save = 10000;
|
||||||
share = true;
|
share = true;
|
||||||
path = "${config.xdg.dataHome}/zsh/history";
|
path = "$HOME/.local/share/zsh/history";
|
||||||
};
|
};
|
||||||
historySubstringSearch = {
|
historySubstringSearch = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -29,7 +26,7 @@ in {
|
||||||
};
|
};
|
||||||
syntaxHighlighting = {
|
syntaxHighlighting = {
|
||||||
enable = true;
|
enable = true;
|
||||||
highlighters = ["brackets" "main" "pattern"];
|
highlighters = [ "brackets" "main" "pattern" ];
|
||||||
styles = {
|
styles = {
|
||||||
arithmetic-expansion = "fg=#ba8baf";
|
arithmetic-expansion = "fg=#ba8baf";
|
||||||
assign = "fg=#7cafc2";
|
assign = "fg=#7cafc2";
|
||||||
|
@ -101,18 +98,17 @@ in {
|
||||||
compinit -C
|
compinit -C
|
||||||
'';
|
'';
|
||||||
plugins = [
|
plugins = [
|
||||||
{
|
{
|
||||||
name = "base16-shell";
|
name = "base16-shell";
|
||||||
src = pkgs.fetchFromGitHub {
|
src = pkgs.fetchFromGitHub {
|
||||||
owner = "chriskempson";
|
owner = "chriskempson";
|
||||||
repo = "base16-shell";
|
repo = "base16-shell";
|
||||||
rev = "588691ba71b47e75793ed9edfcfaa058326a6f41";
|
rev = "588691ba71b47e75793ed9edfcfaa058326a6f41";
|
||||||
hash = "sha256-X89FsG9QICDw3jZvOCB/KsPBVOLUeE7xN3VCtf0DD3E=";
|
hash = "sha256-X89FsG9QICDw3jZvOCB/KsPBVOLUeE7xN3VCtf0DD3E=";
|
||||||
};
|
};
|
||||||
}
|
}];
|
||||||
];
|
|
||||||
localVariables = {
|
localVariables = {
|
||||||
BASE16_THEME = "${config.xdg.configHome}/zsh/plugins/base16";
|
BASE16_THEME = "$HOME/.config/zsh/plugins/base16";
|
||||||
# Make ESC key more reactive to go to normal mode
|
# Make ESC key more reactive to go to normal mode
|
||||||
KEYTIMEOUT = 1;
|
KEYTIMEOUT = 1;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
{...}: {
|
{ ... }:
|
||||||
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./application/foot
|
./application/foot
|
||||||
./application/gnupg
|
./application/gnupg
|
||||||
|
|
|
@ -1,75 +1,18 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.desktop.sway;
|
cfg = config.modules.desktop.sway;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.desktop.sway = {
|
options.modules.desktop.sway = {
|
||||||
enable = mkEnableOption "enable Sway Windows Manager";
|
enable = mkEnableOption "enable Sway Windows Manager";
|
||||||
|
|
||||||
kanshi.enable = mkOption {
|
kanshi = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
description = "configure laptop mode";
|
description = "configure laptop mode";
|
||||||
};
|
};
|
||||||
|
|
||||||
kanshi.standalone = mkOption {
|
|
||||||
type = types.attrs;
|
|
||||||
default = {
|
|
||||||
profile.name = "standalone";
|
|
||||||
profile.outputs = [
|
|
||||||
{
|
|
||||||
criteria = "eDP-1";
|
|
||||||
scale = 1.325;
|
|
||||||
status = "enable";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
description = ''
|
|
||||||
Default configuration for laptop internal screen when no others screen
|
|
||||||
are connected.
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
kanshi.home = mkOption {
|
|
||||||
type = types.attrs;
|
|
||||||
default = {
|
|
||||||
profile.name = "home";
|
|
||||||
profile.outputs = [
|
|
||||||
{
|
|
||||||
criteria = "Iiyama North America PL2792UH 1166310803122";
|
|
||||||
mode = "3840x2160";
|
|
||||||
position = "1235,0";
|
|
||||||
scale = 1.75;
|
|
||||||
}
|
|
||||||
{
|
|
||||||
criteria = "Iiyama North America PL2792UH 1176923201598";
|
|
||||||
mode = "3840x2160";
|
|
||||||
position = "0,0";
|
|
||||||
transform = "90";
|
|
||||||
scale = 1.75;
|
|
||||||
}
|
|
||||||
{
|
|
||||||
criteria = "eDP-1";
|
|
||||||
status = "disable";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
description = ''
|
|
||||||
Default home configuration use on most of my laptops
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
kanshi.others = mkOption {
|
|
||||||
type = types.listOf types.attrs;
|
|
||||||
default = [];
|
|
||||||
description = ''
|
|
||||||
Kanshi profile to use specifically for host
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
swaylock.useNullPackage = mkOption {
|
swaylock.useNullPackage = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
default = false;
|
default = false;
|
||||||
|
@ -103,24 +46,6 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
iconTheme = mkOption {
|
|
||||||
type = types.package;
|
|
||||||
default = pkgs.papirus-icon-theme;
|
|
||||||
description = ''Icon theme package to use'';
|
|
||||||
};
|
|
||||||
|
|
||||||
iconThemeName = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "Papirus Dark";
|
|
||||||
description = ''Icon theme variant to use'';
|
|
||||||
};
|
|
||||||
|
|
||||||
iconThemePathname = mkOption {
|
|
||||||
type = types.str;
|
|
||||||
default = "Papirus-Dark";
|
|
||||||
description = ''Icon theme variant to use'';
|
|
||||||
};
|
|
||||||
|
|
||||||
waybar = {
|
waybar = {
|
||||||
laptop = mkOption {
|
laptop = mkOption {
|
||||||
type = types.bool;
|
type = types.bool;
|
||||||
|
@ -129,9 +54,10 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
cpuThermal = {
|
cpuThermal = {
|
||||||
|
|
||||||
thermalZone = mkOption {
|
thermalZone = mkOption {
|
||||||
type = types.nullOr types.int;
|
type = types.str;
|
||||||
default = null;
|
default = "";
|
||||||
description = "CPU thermal hwmon thermal Zone";
|
description = "CPU thermal hwmon thermal Zone";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -173,6 +99,7 @@ in {
|
||||||
./includes/waybar.nix
|
./includes/waybar.nix
|
||||||
];
|
];
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
|
||||||
programs.fuzzel.enable = true;
|
programs.fuzzel.enable = true;
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
|
@ -180,8 +107,6 @@ in {
|
||||||
# emojione
|
# emojione
|
||||||
font-awesome
|
font-awesome
|
||||||
grim
|
grim
|
||||||
hicolor-icon-theme
|
|
||||||
jq
|
|
||||||
lato
|
lato
|
||||||
liberation_ttf
|
liberation_ttf
|
||||||
libertine
|
libertine
|
||||||
|
@ -192,7 +117,6 @@ in {
|
||||||
noto-fonts-cjk-sans
|
noto-fonts-cjk-sans
|
||||||
slurp
|
slurp
|
||||||
wl-clipboard
|
wl-clipboard
|
||||||
wl-screenrec
|
|
||||||
xdg-utils
|
xdg-utils
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -209,8 +133,8 @@ in {
|
||||||
package = pkgs.arc-theme;
|
package = pkgs.arc-theme;
|
||||||
};
|
};
|
||||||
iconTheme = {
|
iconTheme = {
|
||||||
name = cfg.iconThemeName;
|
name = "Papirus Dark";
|
||||||
package = cfg.iconTheme;
|
package = pkgs.papirus-icon-theme;
|
||||||
};
|
};
|
||||||
font = {
|
font = {
|
||||||
name = "Deja Vu Sans";
|
name = "Deja Vu Sans";
|
||||||
|
@ -236,11 +160,11 @@ in {
|
||||||
QT_SCALE_FACTOR_ROUNDING_POLICY = "RoundPreferFloor";
|
QT_SCALE_FACTOR_ROUNDING_POLICY = "RoundPreferFloor";
|
||||||
};
|
};
|
||||||
|
|
||||||
qt = {
|
qt = {
|
||||||
enable = true;
|
enable = true;
|
||||||
platformTheme.name = "adwaita";
|
platformTheme.name = "adwaita";
|
||||||
style.name = "adwaita-dark";
|
style.name = "adwaita-dark";
|
||||||
};
|
};
|
||||||
xdg = {
|
xdg = {
|
||||||
enable = true;
|
enable = true;
|
||||||
mimeApps.enable = true;
|
mimeApps.enable = true;
|
||||||
|
@ -262,28 +186,26 @@ in {
|
||||||
xdg-desktop-portal-wlr
|
xdg-desktop-portal-wlr
|
||||||
xdg-desktop-portal-gtk
|
xdg-desktop-portal-gtk
|
||||||
];
|
];
|
||||||
xdgOpenUsePortal = false;
|
xdgOpenUsePortal = true;
|
||||||
config = {
|
config = {
|
||||||
sway = {
|
sway = {
|
||||||
default = [
|
default = [
|
||||||
"wlr"
|
"wlr"
|
||||||
"gtk"
|
"gtk"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# When using `useDistributionPackage`, create wlr configuration to let user
|
# When using `useDistributionPackage`, create wlr configuration to let user
|
||||||
# choose the right screen. This is a workarount to not have to configure
|
# choose the right screen. This is a workarount to not have to configure
|
||||||
# it manually.
|
# it manually.
|
||||||
home.file = mkIf cfg.xdg.useDistributionPortals {
|
home.file."${config.xdg.configHome}/xdg-desktop-portal-wlr/config".text = mkIf cfg.xdg.useDistributionPortals ''
|
||||||
"${config.xdg.configHome}/xdg-desktop-portal-wlr/config".text = ''
|
[screencast]
|
||||||
[screencast]
|
max_fps=30
|
||||||
max_fps=30
|
chooser_type=simple
|
||||||
chooser_type=simple
|
chooser_cmd=${pkgs.slurp}/bin/slurp -f %o -or
|
||||||
chooser_cmd=${pkgs.slurp}/bin/slurp -f %o -or
|
'';
|
||||||
'';
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,161 +0,0 @@
|
||||||
#!/usr/bin/env bash
|
|
||||||
set -eu -o pipefail
|
|
||||||
|
|
||||||
APP_NAME="ScreenCapt"
|
|
||||||
|
|
||||||
declare -A COMMAND
|
|
||||||
COMMAND=(
|
|
||||||
[screenshot]="grim"
|
|
||||||
[video]="wl-screenrec"
|
|
||||||
)
|
|
||||||
declare -A ICONS
|
|
||||||
ICONS=(
|
|
||||||
["screenshot"]="accessories-screenshot"
|
|
||||||
["video"]="record-desktop"
|
|
||||||
)
|
|
||||||
|
|
||||||
declare -A OUTPUT_DIR
|
|
||||||
OUTPUT_DIR=(
|
|
||||||
["screenshot"]="${XDG_PICTURES_DIR:-"~/pictures"}/screenshots"
|
|
||||||
["video"]="${XDG_VIDEOS_DIR:="~/videos"}/screenrecords"
|
|
||||||
)
|
|
||||||
|
|
||||||
declare -A OUTPUT_FILE_EXT
|
|
||||||
OUTPUT_FILE_EXT=(
|
|
||||||
["screenshot"]="png"
|
|
||||||
["video"]="mp4"
|
|
||||||
)
|
|
||||||
|
|
||||||
TO_FILE=0
|
|
||||||
RECORD_AUDIO=0
|
|
||||||
ACTION="screenshot"
|
|
||||||
REGION_TYPE="window"
|
|
||||||
|
|
||||||
notify() {
|
|
||||||
local summary message command
|
|
||||||
filename="${1:-""}"
|
|
||||||
summary="New ${ACTION}!"
|
|
||||||
if [[ $TO_FILE -eq 1 ]]; then
|
|
||||||
message+="Available in <i>${filename##*/}</i>"
|
|
||||||
else
|
|
||||||
message+="Available in the clipboard"
|
|
||||||
fi
|
|
||||||
command=(notify-send "${summary}" --app-name="$APP_NAME")
|
|
||||||
if [[ -n "$filename" && "$ACTION" == "screenshot" ]]; then
|
|
||||||
command+=(--icon="${filename}")
|
|
||||||
else
|
|
||||||
command+=("--icon=${ICONS[$ACTION]}")
|
|
||||||
fi
|
|
||||||
command+=("$message")
|
|
||||||
"${command[@]}"
|
|
||||||
}
|
|
||||||
|
|
||||||
process_args() {
|
|
||||||
while :; do
|
|
||||||
case ''${1:-""} in
|
|
||||||
screenshot)
|
|
||||||
ACTION="$1"
|
|
||||||
;;
|
|
||||||
|
|
||||||
video)
|
|
||||||
# If a video record is in progress Stop it
|
|
||||||
if pgrep "wl-screenrec"; then
|
|
||||||
kill -s SIGINT $(pgrep "wl-screenrec")
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
TO_FILE=1
|
|
||||||
ACTION="$1"
|
|
||||||
;;
|
|
||||||
-r | --region)
|
|
||||||
if [[ "${2:-""}" =~ ^(r|region|s|screen|w|window)$ ]]; then
|
|
||||||
REGION_TYPE="$2"
|
|
||||||
else
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
shift
|
|
||||||
;;
|
|
||||||
-f | --file)
|
|
||||||
TO_FILE=1
|
|
||||||
;;
|
|
||||||
-a | --with-audio)
|
|
||||||
RECORD_AUDIO=1
|
|
||||||
;;
|
|
||||||
*)
|
|
||||||
break
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
shift
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
get_app_name() {
|
|
||||||
local appname
|
|
||||||
case "$REGION_TYPE" in
|
|
||||||
r | region)
|
|
||||||
appname="region"
|
|
||||||
;;
|
|
||||||
s | screen)
|
|
||||||
appname="screen"
|
|
||||||
;;
|
|
||||||
w | window)
|
|
||||||
appname=$(swaymsg -t get_tree | jq -r '.. | ((.nodes? // empty) + (.floating_nodes? // empty))[] | select(.visible and .pid and .focused) | "\(.app_id)"')
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
printf "%s" "${appname:-}"
|
|
||||||
}
|
|
||||||
|
|
||||||
get_region() {
|
|
||||||
local region switch
|
|
||||||
case "$REGION_TYPE" in
|
|
||||||
r | region)
|
|
||||||
region=$(slurp)
|
|
||||||
switch="-g"
|
|
||||||
;;
|
|
||||||
s | screen)
|
|
||||||
region=$(swaymsg -t get_outputs | jq -r '.[] | select(.focused) | "\(.name)"')
|
|
||||||
switch="-o"
|
|
||||||
;;
|
|
||||||
w | window)
|
|
||||||
region=$(swaymsg -t get_tree | jq -r '.. | ((.nodes? // empty) + (.floating_nodes? // empty))[] | select(.visible and .pid and .focused) | .rect | "\(.x),\(.y) \(.width)x\(.height)"')
|
|
||||||
switch="-g"
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
printf "%s%s" "${switch:-}" "${region:-}"
|
|
||||||
}
|
|
||||||
|
|
||||||
get_output_filename() {
|
|
||||||
local date
|
|
||||||
printf -v date '%(%F_%H.%M.%S)T'
|
|
||||||
printf "%s/%s-%s.%s" "${OUTPUT_DIR[$ACTION]}" "$date" "$(get_app_name)" "${OUTPUT_FILE_EXT[$ACTION]}"
|
|
||||||
}
|
|
||||||
|
|
||||||
ensure_directories_exist() {
|
|
||||||
for dir in "${!OUTPUT_DIR[@]}"; do
|
|
||||||
mkdir -p "${OUTPUT_DIR[$dir]}"
|
|
||||||
done
|
|
||||||
}
|
|
||||||
|
|
||||||
main() {
|
|
||||||
process_args "$@"
|
|
||||||
ensure_directories_exist
|
|
||||||
local command
|
|
||||||
command=("${COMMAND[$ACTION]}" "$(get_region)")
|
|
||||||
if [[ "$TO_FILE" -eq 1 ]]; then
|
|
||||||
local filename
|
|
||||||
filename=$(get_output_filename)
|
|
||||||
if [[ "$ACTION" = "video" ]]; then
|
|
||||||
if [[ "$RECORD_AUDIO" -eq 1 ]]; then
|
|
||||||
command+=(--audio)
|
|
||||||
fi
|
|
||||||
command+=(-f)
|
|
||||||
fi
|
|
||||||
command+=("$filename")
|
|
||||||
"${command[@]}"
|
|
||||||
else
|
|
||||||
"${command[@]}" - | wl-copy
|
|
||||||
fi
|
|
||||||
notify "${filename:-""}"
|
|
||||||
exit 0
|
|
||||||
}
|
|
||||||
|
|
||||||
main "$@"
|
|
|
@ -1,134 +0,0 @@
|
||||||
@define-color color-base-bg #323232;
|
|
||||||
@define-color color-base-fg #ddd;
|
|
||||||
|
|
||||||
@define-color color-hover #f268b3;
|
|
||||||
@define-color color-selected #1cd180;
|
|
||||||
|
|
||||||
@define-color color-ok #1cd180;
|
|
||||||
@define-color color-warning #f2b768;
|
|
||||||
@define-color color-critical #f268b3;
|
|
||||||
|
|
||||||
* {
|
|
||||||
border: none;
|
|
||||||
border-radius: 0;
|
|
||||||
min-height:0;
|
|
||||||
}
|
|
||||||
|
|
||||||
window#waybar {
|
|
||||||
background: @color-base-bg ;
|
|
||||||
color: @color-base-fg;
|
|
||||||
font-family: "Fira Code Nerd Font";
|
|
||||||
font-size: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
button,
|
|
||||||
button:disabled,label:disabled{
|
|
||||||
color:inherit;
|
|
||||||
}
|
|
||||||
|
|
||||||
button:hover{
|
|
||||||
background:none;
|
|
||||||
box-shadow:inherit;
|
|
||||||
box-shadow:inherit;
|
|
||||||
text-shadow:inherit;
|
|
||||||
text-shadow:inherit;
|
|
||||||
border-top:none;
|
|
||||||
}
|
|
||||||
#workspaces {
|
|
||||||
color:#fff;
|
|
||||||
}
|
|
||||||
#workspaces button {
|
|
||||||
margin:0 3px;
|
|
||||||
padding:4px 4px;
|
|
||||||
color:#9c9c9c;
|
|
||||||
border-bottom: 1px solid transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
#workspaces button:hover {
|
|
||||||
box-shadow:inherit;
|
|
||||||
text-shadow:inherit;
|
|
||||||
color: @color-hover;
|
|
||||||
border-bottom: 1px solid @color-hover;
|
|
||||||
}
|
|
||||||
|
|
||||||
#workspaces button.focused {
|
|
||||||
background: @color-selected;
|
|
||||||
color: @color-base-bg;
|
|
||||||
}
|
|
||||||
#workspaces button.visible:not(.focused) {
|
|
||||||
color: @color-selected;
|
|
||||||
border-color: @color-selected;
|
|
||||||
}
|
|
||||||
|
|
||||||
#clock,
|
|
||||||
#cpu,
|
|
||||||
#memory,
|
|
||||||
#backlight,
|
|
||||||
#network,
|
|
||||||
#tray,
|
|
||||||
#mode,
|
|
||||||
#battery,
|
|
||||||
#idle_inhibitor {
|
|
||||||
padding: 2px 4px;
|
|
||||||
margin: 0;
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
#mode{
|
|
||||||
background:@color-warning;
|
|
||||||
color: @color-base-bg;
|
|
||||||
font-weight:200;
|
|
||||||
font-variant: small-caps;
|
|
||||||
font-size: 16px;
|
|
||||||
}
|
|
||||||
#pulseaudio {}
|
|
||||||
#pulseaudio.output.muted {
|
|
||||||
color:@color-critical;
|
|
||||||
}
|
|
||||||
#pulseaudio.input.source-muted {
|
|
||||||
color:@color-critical;
|
|
||||||
}
|
|
||||||
|
|
||||||
#battery.discharging {
|
|
||||||
color: @color-base-fg;
|
|
||||||
border-bottom: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#battery.charging, #battery.plugged {
|
|
||||||
border-bottom: 1px solid @color-ok;
|
|
||||||
color: @color-selected;
|
|
||||||
}
|
|
||||||
|
|
||||||
#battery.critical:not(.charging),
|
|
||||||
#cpu.critical,
|
|
||||||
#memory.critical,
|
|
||||||
#temperature.critical{
|
|
||||||
border-color: @color-critical;
|
|
||||||
color: @color-critical;
|
|
||||||
}
|
|
||||||
|
|
||||||
#battery.warning:not(.charging),
|
|
||||||
#cpu.warning,
|
|
||||||
#memory.warning{
|
|
||||||
border-color: @color-warning;
|
|
||||||
color: @color-warning;
|
|
||||||
}
|
|
||||||
|
|
||||||
#tray {
|
|
||||||
font-family: "DejaVu sans";
|
|
||||||
font-size: 12px;
|
|
||||||
}
|
|
||||||
#custom-screenrecord {
|
|
||||||
color: @color-critical;
|
|
||||||
border-bottom: 1px solid @color-critical;
|
|
||||||
animation-name: critical-animation;
|
|
||||||
animation-duration: 2s;
|
|
||||||
animation-timing-function: ease-in-out;
|
|
||||||
animation-direction: alternate;
|
|
||||||
animation-iteration-count: infinite;
|
|
||||||
}
|
|
||||||
|
|
||||||
@keyframes critical-animation {
|
|
||||||
from {color: @color-critical;}
|
|
||||||
to {color: white;}
|
|
||||||
}
|
|
|
@ -1,9 +1,6 @@
|
||||||
|
{ config, lib, ... }:
|
||||||
|
with lib;
|
||||||
{
|
{
|
||||||
config,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; {
|
|
||||||
config = mkIf config.modules.desktop.sway.enable {
|
config = mkIf config.modules.desktop.sway.enable {
|
||||||
programs.fuzzel = {
|
programs.fuzzel = {
|
||||||
settings = {
|
settings = {
|
||||||
|
@ -28,5 +25,5 @@ with lib; {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,20 +1,61 @@
|
||||||
|
{ config, lib, ... }:
|
||||||
|
with lib;
|
||||||
{
|
{
|
||||||
config,
|
config = mkIf config.modules.desktop.sway.enable {
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.desktop.sway;
|
|
||||||
in {
|
|
||||||
config = mkIf cfg.enable {
|
|
||||||
services.kanshi = {
|
services.kanshi = {
|
||||||
enable = cfg.kanshi.enable;
|
enable = config.modules.desktop.sway.kanshi ;
|
||||||
settings =
|
settings = [
|
||||||
[
|
{
|
||||||
cfg.kanshi.standalone
|
|
||||||
cfg.kanshi.home
|
profile.name = "standalone";
|
||||||
]
|
profile.outputs = [
|
||||||
++ cfg.kanshi.others;
|
{
|
||||||
|
criteria = "eDP-1";
|
||||||
|
scale = 1.33;
|
||||||
|
status = "enable";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
{
|
||||||
|
profile.name = "home";
|
||||||
|
profile.outputs = [
|
||||||
|
{
|
||||||
|
criteria = "Iiyama North America PL2792UH 1166310803122";
|
||||||
|
mode = "3840x2160";
|
||||||
|
position = "1235,0";
|
||||||
|
scale = 1.75;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
criteria = "Iiyama North America PL2792UH 1176923201598";
|
||||||
|
mode = "3840x2160";
|
||||||
|
position = "0,0";
|
||||||
|
transform = "90";
|
||||||
|
scale = 1.75;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
criteria = "eDP-1";
|
||||||
|
status = "disable";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
{
|
||||||
|
profile.name = "work";
|
||||||
|
profile.outputs = [
|
||||||
|
{
|
||||||
|
criteria = "Iiyama North America PL2792QN 1179214201663";
|
||||||
|
mode = "2560x1440";
|
||||||
|
position = "1450,0";
|
||||||
|
scale = 1.15;
|
||||||
|
}
|
||||||
|
{
|
||||||
|
criteria = "BOE 0x0A95 Unknown";
|
||||||
|
mode = "1920x1080";
|
||||||
|
position = "0,0";
|
||||||
|
scale = 1.325;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,20 +1,14 @@
|
||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
with lib;
|
||||||
{
|
{
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.desktop.sway;
|
|
||||||
in {
|
|
||||||
config = mkIf config.modules.desktop.sway.enable {
|
config = mkIf config.modules.desktop.sway.enable {
|
||||||
systemd.user.services.mako = {
|
systemd.user.services.mako = {
|
||||||
Service = {
|
Service = {
|
||||||
ExecStart = "${pkgs.mako}/bin/mako";
|
ExecStart = "${pkgs.mako}/bin/mako";
|
||||||
};
|
};
|
||||||
Install = {
|
Install = {
|
||||||
After = ["sway-session.target"];
|
After = [ "sway-session.target" ];
|
||||||
WantedBy = ["sway-session.target"];
|
WantedBy = [ "sway-session.target" ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
services.mako = {
|
services.mako = {
|
||||||
|
@ -30,11 +24,12 @@ in {
|
||||||
border-radius = 0;
|
border-radius = 0;
|
||||||
border-size = 2;
|
border-size = 2;
|
||||||
icons = true;
|
icons = true;
|
||||||
icon-path = "${cfg.iconTheme}/share/icons/${cfg.iconThemePathname}";
|
|
||||||
max-icon-size = 64;
|
max-icon-size = 64;
|
||||||
layer = "overlay";
|
layer = "overlay";
|
||||||
anchor = "top-right";
|
anchor = "top-right";
|
||||||
format = ''<span font_scale='small-caps'>%a</span>\n<b>%s</b>\n%b'';
|
format = ''
|
||||||
|
<span font_scale='small-caps'>%a</span>\n<b>%s</b>\n%b
|
||||||
|
'';
|
||||||
"urgency=high" = {
|
"urgency=high" = {
|
||||||
border-color = "#F268b3";
|
border-color = "#F268b3";
|
||||||
};
|
};
|
||||||
|
@ -42,10 +37,10 @@ in {
|
||||||
border-size = 1;
|
border-size = 1;
|
||||||
default-timeout = 7000;
|
default-timeout = 7000;
|
||||||
group-by = "app-name";
|
group-by = "app-name";
|
||||||
format = "%b";
|
format= "%b";
|
||||||
};
|
};
|
||||||
"app-name=cmus grouped" = {
|
"app-name=cmus grouped" = {
|
||||||
format = "%b";
|
format = "%b";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,16 +1,13 @@
|
||||||
{
|
{ config, pkgs, lib, ... }:
|
||||||
config,
|
with lib;
|
||||||
pkgs,
|
let
|
||||||
lib,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.desktop.sway;
|
cfg = config.modules.desktop.sway;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
config = mkIf config.modules.desktop.sway.enable {
|
config = mkIf config.modules.desktop.sway.enable {
|
||||||
wayland.windowManager.sway = {
|
wayland.windowManager.sway = {
|
||||||
package = config.lib.nixGL.wrap pkgs.sway;
|
package = config.lib.nixGL.wrap pkgs.sway;
|
||||||
enable = true;
|
enable = true;
|
||||||
wrapperFeatures.gtk = true;
|
wrapperFeatures.gtk = true;
|
||||||
systemd.enable = true;
|
systemd.enable = true;
|
||||||
config = {
|
config = {
|
||||||
|
@ -20,7 +17,7 @@ in {
|
||||||
down = "j";
|
down = "j";
|
||||||
up = "k";
|
up = "k";
|
||||||
right = "l";
|
right = "l";
|
||||||
bars = [];
|
bars= [];
|
||||||
input = {
|
input = {
|
||||||
"4617:27904:MNT_Research_MNT_Reform_Keyboard_2.0_US/ST" = {
|
"4617:27904:MNT_Research_MNT_Reform_Keyboard_2.0_US/ST" = {
|
||||||
xkb_layout = "us";
|
xkb_layout = "us";
|
||||||
|
@ -37,16 +34,11 @@ in {
|
||||||
};
|
};
|
||||||
keybindings = let
|
keybindings = let
|
||||||
mod = config.wayland.windowManager.sway.config.modifier;
|
mod = config.wayland.windowManager.sway.config.modifier;
|
||||||
inherit
|
inherit (config.wayland.windowManager.sway.config)
|
||||||
(config.wayland.windowManager.sway.config)
|
left down up right terminal;
|
||||||
left
|
in
|
||||||
down
|
{
|
||||||
up
|
# navigate only with direction or workspace
|
||||||
right
|
|
||||||
terminal
|
|
||||||
;
|
|
||||||
in {
|
|
||||||
# navigate only with direction or workspace
|
|
||||||
"${mod}+${left}" = "focus left";
|
"${mod}+${left}" = "focus left";
|
||||||
"${mod}+${down}" = "focus down";
|
"${mod}+${down}" = "focus down";
|
||||||
"${mod}+${up}" = "focus up";
|
"${mod}+${up}" = "focus up";
|
||||||
|
@ -61,7 +53,7 @@ in {
|
||||||
"${mod}+8" = "workspace $ws8";
|
"${mod}+8" = "workspace $ws8";
|
||||||
"${mod}+9" = "workspace $ws9";
|
"${mod}+9" = "workspace $ws9";
|
||||||
"${mod}+0" = "workspace $ws0";
|
"${mod}+0" = "workspace $ws0";
|
||||||
# move with Shift and direction
|
# move with Shift and direction
|
||||||
"${mod}+Shift+${left}" = "move left";
|
"${mod}+Shift+${left}" = "move left";
|
||||||
"${mod}+Shift+${down}" = "move down";
|
"${mod}+Shift+${down}" = "move down";
|
||||||
"${mod}+Shift+${up}" = "move up";
|
"${mod}+Shift+${up}" = "move up";
|
||||||
|
@ -80,15 +72,12 @@ in {
|
||||||
"${mod}+Ctrl+${left}" = "move workspace to output left";
|
"${mod}+Ctrl+${left}" = "move workspace to output left";
|
||||||
"${mod}+Return" = "exec ${terminal}";
|
"${mod}+Return" = "exec ${terminal}";
|
||||||
"${mod}+d" = "exec ${pkgs.fuzzel}/bin/fuzzel";
|
"${mod}+d" = "exec ${pkgs.fuzzel}/bin/fuzzel";
|
||||||
# manage windows manager actions with Alt
|
# manage windows manager actions with Alt
|
||||||
"${mod}+Alt+k" = "kill";
|
"${mod}+Alt+k" = "kill";
|
||||||
"${mod}+Alt+c" = "reload";
|
"${mod}+Alt+c" = "reload";
|
||||||
"${mod}+Alt+Backspace" = "exec swaynag -t warning -m 'Exit sway?' -B 'Yes' 'swaymsg exit'";
|
"${mod}+Alt+Backspace" = "exec swaynag -t warning -m 'Exit sway?' -B 'Yes' 'swaymsg exit'";
|
||||||
"${mod}+Alt+l" =
|
"${mod}+Alt+l" = if cfg.swaylock.useNullPackage then "exec swaylock" else "exec ${pkgs.swaylock}/bin/swaylock";
|
||||||
if cfg.swaylock.useNullPackage
|
# Manage windows placement
|
||||||
then "exec swaylock"
|
|
||||||
else "exec ${pkgs.swaylock}/bin/swaylock";
|
|
||||||
# Manage windows placement
|
|
||||||
"${mod}+b" = "splith";
|
"${mod}+b" = "splith";
|
||||||
"${mod}+v" = "splitv";
|
"${mod}+v" = "splitv";
|
||||||
"${mod}+s" = "layout stacking";
|
"${mod}+s" = "layout stacking";
|
||||||
|
@ -98,13 +87,9 @@ in {
|
||||||
"${mod}+Shift+space" = "floating toggle";
|
"${mod}+Shift+space" = "floating toggle";
|
||||||
"${mod}+space" = "focus mode_toggle";
|
"${mod}+space" = "focus mode_toggle";
|
||||||
"${mod}+a" = "focus parent";
|
"${mod}+a" = "focus parent";
|
||||||
"${mod}+Shift+minus" = "move scratchpad";
|
"${mod}+Shift+p" = "move scratchpad";
|
||||||
"${mod}+minus" = "scratchpad show";
|
"${mod}+p" = "scratchpad show";
|
||||||
"${mod}+p" = "exec screencapt --region window";
|
# Media stuff
|
||||||
"${mod}+Shift+p" = "exec screencapt --region screen";
|
|
||||||
"${mod}+Alt+p" = "mode screenshot";
|
|
||||||
"${mod}+Alt+r" = "mode screenrecord";
|
|
||||||
# Media stuff
|
|
||||||
"${mod}+F1" = "exec ${pkgs.brightnessctl}/bin/brightnessctl s 1%-";
|
"${mod}+F1" = "exec ${pkgs.brightnessctl}/bin/brightnessctl s 1%-";
|
||||||
"${mod}+F2" = "exec ${pkgs.brightnessctl}/bin/brightnessctl s +1%";
|
"${mod}+F2" = "exec ${pkgs.brightnessctl}/bin/brightnessctl s +1%";
|
||||||
"${mod}+F3" = "exec ${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_SINK@ 5%-";
|
"${mod}+F3" = "exec ${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_SINK@ 5%-";
|
||||||
|
@ -116,47 +101,23 @@ in {
|
||||||
"${mod}+shift+n" = "exec makoctl dismiss -a";
|
"${mod}+shift+n" = "exec makoctl dismiss -a";
|
||||||
"${mod}+alt+n" = "mode notification";
|
"${mod}+alt+n" = "mode notification";
|
||||||
};
|
};
|
||||||
modes = let
|
modes =
|
||||||
inherit
|
let
|
||||||
(config.wayland.windowManager.sway.config)
|
inherit (config.wayland.windowManager.sway.config)
|
||||||
left
|
left down up right;
|
||||||
down
|
|
||||||
up
|
|
||||||
right
|
|
||||||
;
|
|
||||||
in {
|
in {
|
||||||
"resize" = {
|
"resize" = {
|
||||||
"${left}" = "resize shrink width 10 px or 10 ppt";
|
"${left}" = "resize shrink width 10 px or 10 ppt";
|
||||||
"${down}" = "resize grow height 10 px or 10 ppt";
|
"${down}" = "resize grow height 10 px or 10 ppt";
|
||||||
"${up}" = "resize shrink height 10 px or 10 ppt";
|
"${up}" = "resize shrink height 10 px or 10 ppt";
|
||||||
"${right}" = "resize grow width 10 px or 10 ppt";
|
"${right}" = "resize grow width 10 px or 10 ppt";
|
||||||
"Return" = "mode default";
|
"Return" = "mode default";
|
||||||
"Escape" = "mode default";
|
"Escape" = "mode default";
|
||||||
};
|
};
|
||||||
"notification" = {
|
"notification" = {
|
||||||
"r" = "exec ${pkgs.mako}/bin/makoctl restore";
|
"r" = "exec ${pkgs.mako}/bin/makoctl restore";
|
||||||
"Escape" = "mode default";
|
"Escape" = "mode default";
|
||||||
};
|
};
|
||||||
"screenshot" = {
|
|
||||||
"s" = "exec screencapt --region screen; mode default";
|
|
||||||
"Shift+s" = "exec screencapt --region screen -f; mode default";
|
|
||||||
"r" = "exec screencapt --region region; mode default";
|
|
||||||
"Shift+r" = "exec screencapt --region region -f; mode default";
|
|
||||||
"w" = "exec screencapt --region window; mode default";
|
|
||||||
"Shift+w" = "exec screencapt --region window -f; mode default";
|
|
||||||
"Return" = "mode default";
|
|
||||||
"Escape" = "mode default";
|
|
||||||
};
|
|
||||||
"screenrecord" = {
|
|
||||||
"s" = "exec screencapt video --region screen; mode default";
|
|
||||||
"Shift+s" = "exec screencapt --region video screen -a; mde default";
|
|
||||||
"r" = "exec screencapt video --region region; mode default";
|
|
||||||
"Shift+r" = "exec screencapt video --region region -a; mode default";
|
|
||||||
"w" = "exec screencapt video --region window -f ; mode default";
|
|
||||||
"Shift+w" = "exec screencapt --region video window -a; mode default";
|
|
||||||
"Return" = "mode default";
|
|
||||||
"Escape" = "mode default";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
colors = {
|
colors = {
|
||||||
focused = {
|
focused = {
|
||||||
|
@ -185,7 +146,7 @@ in {
|
||||||
background = "#900000";
|
background = "#900000";
|
||||||
text = "#cccccc";
|
text = "#cccccc";
|
||||||
indicator = "#900000";
|
indicator = "#900000";
|
||||||
childBorder = "#900000";
|
childBorder = "#900000" ;
|
||||||
};
|
};
|
||||||
#focused_tab_title = {
|
#focused_tab_title = {
|
||||||
# boder = "#2f343a";
|
# boder = "#2f343a";
|
||||||
|
@ -197,33 +158,32 @@ in {
|
||||||
border = 1;
|
border = 1;
|
||||||
titlebar = false;
|
titlebar = false;
|
||||||
commands = [
|
commands = [
|
||||||
{
|
{
|
||||||
command = "inhibit_idle fullscreen";
|
command = "inhibit_idle fullscreen";
|
||||||
criteria = {
|
criteria = {
|
||||||
title = "^.*";
|
title = "^.*";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
command = "inhibit_idle fullscreen";
|
command = "inhibit_idle fullscreen";
|
||||||
criteria = {
|
criteria = {
|
||||||
app_id = "^.*";
|
app_id = "^.*";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
command = "resize set 70ppt 70ppt, border pixel 2";
|
command = "resize set 70ppt 70ppt, border pixel 2";
|
||||||
criteria = {
|
criteria = {
|
||||||
title = "^Open .*$";
|
title = "^Open .*$";
|
||||||
};
|
};
|
||||||
}
|
}];
|
||||||
];
|
|
||||||
};
|
};
|
||||||
floating = {
|
floating = {
|
||||||
border = 2;
|
border = 2;
|
||||||
titlebar = false;
|
titlebar = false;
|
||||||
criteria = [
|
criteria = [
|
||||||
{
|
{
|
||||||
title = "^Open .*$";
|
title = "^Open .*$";
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
gaps = {
|
gaps = {
|
||||||
|
@ -254,9 +214,5 @@ in {
|
||||||
title_align right
|
title_align right
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
home.file.".local/bin/screencapt" = {
|
|
||||||
executable = true;
|
|
||||||
source = ./files/screencapt.sh;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,43 +1,31 @@
|
||||||
{
|
{ config, lib, pkgs, ... }:
|
||||||
config,
|
with lib;
|
||||||
lib,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.desktop.sway;
|
cfg = config.modules.desktop.sway;
|
||||||
in {
|
in
|
||||||
config = mkIf config.modules.desktop.sway.enable {
|
{
|
||||||
|
config = mkIf config.modules.desktop.sway.enable {
|
||||||
services.swayidle = {
|
services.swayidle = {
|
||||||
enable = true;
|
enable = true;
|
||||||
timeouts = [
|
timeouts = [
|
||||||
{
|
{
|
||||||
timeout = 300;
|
timeout = 300;
|
||||||
command =
|
command = if cfg.swaylock.useNullPackage then ''/usr/bin/swaylock -f'' else ''${pkgs.swaylock}/bin/swaylock -f'';
|
||||||
if cfg.swaylock.useNullPackage
|
|
||||||
then ''/usr/bin/swaylock -f''
|
|
||||||
else ''${pkgs.swaylock}/bin/swaylock -f'';
|
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
timeout = 600;
|
timeout = 600;
|
||||||
command = ''${pkgs.sway}/bin/swaymsg "output * power off"'';
|
command = ''${pkgs.sway}/bin/swaymsg "output * power off"'';
|
||||||
resumeCommand = ''${pkgs.sway}/bin/swaymsg "output * power on"'';
|
resumeCommand =''${pkgs.sway}/bin/swaymsg "output * power on"'';
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
events = [
|
events = [
|
||||||
{
|
{
|
||||||
event = "before-sleep";
|
event = "before-sleep";
|
||||||
command =
|
command = if cfg.swaylock.useNullPackage then ''/usr/bin/swaylock -f'' else ''${pkgs.swaylock}/bin/swaylock -f'';
|
||||||
if cfg.swaylock.useNullPackage
|
|
||||||
then ''/usr/bin/swaylock -f''
|
|
||||||
else ''${pkgs.swaylock}/bin/swaylock -f'';
|
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
event = "lock";
|
event = "lock";
|
||||||
command =
|
command = if cfg.swaylock.useNullPackage then ''usr/bin/swaylock -f'' else ''${pkgs.swaylock}/bin/swaylock -f'';
|
||||||
if cfg.swaylock.useNullPackage
|
|
||||||
then ''usr/bin/swaylock -f''
|
|
||||||
else ''${pkgs.swaylock}/bin/swaylock -f'';
|
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,24 +1,15 @@
|
||||||
{
|
{ config, lib, pkgs, ... }:
|
||||||
config,
|
with lib;
|
||||||
lib,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.desktop.sway;
|
cfg = config.modules.desktop.sway;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
config = mkIf config.modules.desktop.sway.enable {
|
config = mkIf config.modules.desktop.sway.enable {
|
||||||
programs.swaylock = {
|
programs.swaylock = {
|
||||||
package =
|
package = if cfg.swaylock.useNullPackage then null else pkgs.swaylock;
|
||||||
if cfg.swaylock.useNullPackage
|
|
||||||
then null
|
|
||||||
else pkgs.swaylock;
|
|
||||||
enable = true;
|
enable = true;
|
||||||
settings = {
|
settings = {
|
||||||
image =
|
image = if cfg.wallpapers.lockscreen != "" then "${cfg.wallpapers.lockscreen}" else false;
|
||||||
if cfg.wallpapers.lockscreen != ""
|
|
||||||
then "${cfg.wallpapers.lockscreen}"
|
|
||||||
else false;
|
|
||||||
scaling = "center";
|
scaling = "center";
|
||||||
color = "000000";
|
color = "000000";
|
||||||
indicator-radius = 70;
|
indicator-radius = 70;
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
{
|
{lib, config, ...}:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.desktop.sway;
|
cfg = config.modules.desktop.sway;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
programs.waybar = {
|
programs.waybar = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -19,52 +16,44 @@ in {
|
||||||
layer = "top";
|
layer = "top";
|
||||||
spacing = 6;
|
spacing = 6;
|
||||||
disable-toolptips = true;
|
disable-toolptips = true;
|
||||||
modules-center = [
|
modules-center = [];
|
||||||
"custom/screenrecord"
|
|
||||||
];
|
|
||||||
modules-left = [
|
modules-left = [
|
||||||
"sway/workspaces"
|
"sway/workspaces"
|
||||||
"sway/mode"
|
"sway/mode"
|
||||||
];
|
];
|
||||||
modules-right =
|
modules-right = [
|
||||||
[
|
"network"
|
||||||
"network"
|
"custom/sep"
|
||||||
"custom/sep"
|
] ++ (
|
||||||
]
|
if cfg.waybar.laptop then [
|
||||||
++ (
|
|
||||||
if cfg.waybar.laptop
|
|
||||||
then [
|
|
||||||
"backlight"
|
"backlight"
|
||||||
"battery"
|
"battery"
|
||||||
"custom/sep"
|
"custom/sep"
|
||||||
]
|
]
|
||||||
else [
|
else [
|
||||||
]
|
]
|
||||||
)
|
) ++
|
||||||
++ [
|
[
|
||||||
"memory"
|
|
||||||
"cpu"
|
"memory"
|
||||||
"temperature"
|
"cpu"
|
||||||
"custom/sep"
|
"temperature"
|
||||||
]
|
"custom/sep"
|
||||||
++ (
|
] ++ (
|
||||||
if cfg.waybar.gpuThermal.enable
|
if cfg.waybar.gpuThermal.enable then [
|
||||||
then [
|
|
||||||
"temperature#gpu"
|
"temperature#gpu"
|
||||||
"custom/sep"
|
"custom/sep"
|
||||||
]
|
]
|
||||||
else [
|
else [
|
||||||
]
|
]
|
||||||
)
|
) ++
|
||||||
++ [
|
[
|
||||||
"pulseaudio#input"
|
"pulseaudio"
|
||||||
"pulseaudio#output"
|
"custom/sep"
|
||||||
"custom/sep"
|
"clock"
|
||||||
"clock"
|
"custom/sep"
|
||||||
"custom/sep"
|
"tray"
|
||||||
"privacy"
|
];
|
||||||
"tray"
|
|
||||||
];
|
|
||||||
"clock" = {
|
"clock" = {
|
||||||
"format-alt" = "{:%Y-%m-%d}";
|
"format-alt" = "{:%Y-%m-%d}";
|
||||||
"timezone" = "Europe/Paris";
|
"timezone" = "Europe/Paris";
|
||||||
|
@ -72,7 +61,7 @@ in {
|
||||||
};
|
};
|
||||||
"cpu" = {
|
"cpu" = {
|
||||||
"format" = "{usage}% {icon}";
|
"format" = "{usage}% {icon}";
|
||||||
"format-icons" = [""];
|
"format-icons" = [ "" ];
|
||||||
"states" = {
|
"states" = {
|
||||||
"critical" = 90;
|
"critical" = 90;
|
||||||
"warning" = 70;
|
"warning" = 70;
|
||||||
|
@ -83,23 +72,15 @@ in {
|
||||||
"format" = "|";
|
"format" = "|";
|
||||||
"tooltip" = false;
|
"tooltip" = false;
|
||||||
};
|
};
|
||||||
"custom/screenrecord" = {
|
|
||||||
"format" = " [rec.] ";
|
|
||||||
"interval" = 1;
|
|
||||||
"exec" = "echo '{\"class\": \"recording\"}'";
|
|
||||||
"exec-if" = "${pkgs.procps}/bin/pgrep wl-screenrec";
|
|
||||||
"on-click" = "exec ${pkgs.coreutils}/bin/kill -s SIGINT $(${pkgs.procps}/bin/pgrep wl-screenrec)";
|
|
||||||
"tooltype" = false;
|
|
||||||
};
|
|
||||||
"idle_inhibitor" = {
|
"idle_inhibitor" = {
|
||||||
"format" = "{icon}";
|
"format" = "{icon}";
|
||||||
"format-icons" = {
|
"format-icons" = {
|
||||||
"activated" = "";
|
"activated" = "";
|
||||||
"deactivated" = "";
|
"deactivated" = "";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
"memory" = {
|
"memory" = {
|
||||||
"format" = "{used:0.0f}/{total:0.0f}G ";
|
"format" = "{used:0.1f}G/{total:0.1f}G ";
|
||||||
"interval" = 30;
|
"interval" = 30;
|
||||||
"states" = {
|
"states" = {
|
||||||
"critical" = 90;
|
"critical" = 90;
|
||||||
|
@ -107,71 +88,44 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
"network" = {
|
"network" = {
|
||||||
"format-alt" = "{ifname}: {essid} {ipaddr}/{cidr} ";
|
"format-alt" = "{ifname}: {ipaddr}/{cidr}";
|
||||||
"format-disconnected" = "Disconnected ⚠ ";
|
"format-disconnected" = "Disconnected ⚠ ";
|
||||||
"format-ethernet" = "{ifname} ";
|
"format-ethernet" = "{ifname}: {ipaddr}/{cidr} ";
|
||||||
"format-linked" = "{ifname} (No IP) ";
|
"format-linked" = "{ifname} (No IP) ";
|
||||||
"format-wifi" = "{signalStrength}% ";
|
"format-wifi" = "{essid} ({signalStrength}%) ";
|
||||||
"tooltip" = false;
|
"tooltip" = false;
|
||||||
};
|
};
|
||||||
"privacy" = {
|
"pulseaudio" = {
|
||||||
"icon-spacing" = 6;
|
"format" = "{format_source} {volume}% {icon} ";
|
||||||
"icon-size" = 11;
|
|
||||||
"transition-duration" = 250;
|
|
||||||
"modules" = [
|
|
||||||
{
|
|
||||||
"type" = "screenshare";
|
|
||||||
"tooltip" = false;
|
|
||||||
}
|
|
||||||
{
|
|
||||||
"type" = "audio-out";
|
|
||||||
"tooltip" = false;
|
|
||||||
}
|
|
||||||
{
|
|
||||||
"type" = "audio-in";
|
|
||||||
"tooltip" = false;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
"ignore-monitor" = true;
|
|
||||||
};
|
|
||||||
"pulseaudio#output" = {
|
|
||||||
"format" = "{volume}% {icon} ";
|
|
||||||
"format-bluetooth" = "{volume}% {icon}";
|
"format-bluetooth" = "{volume}% {icon}";
|
||||||
"format-icons" = {
|
"format-icons" = {
|
||||||
"car" = "";
|
"car" = "";
|
||||||
"default" = "";
|
"default" = "";
|
||||||
"hands-free" = "";
|
"hands-free" = "";
|
||||||
"headphone" = "";
|
"headphone" = "";
|
||||||
"headset" = "";
|
"headset" = "";
|
||||||
"phone" = "";
|
"phone" = "";
|
||||||
"portable" = "";
|
"portable" = "";
|
||||||
};
|
};
|
||||||
"format-muted" = " ";
|
"format-muted" = "{format_source} ";
|
||||||
"tooltip" = false;
|
"format-source" = "{volume}% ";
|
||||||
};
|
|
||||||
"pulseaudio#input" = {
|
|
||||||
"format" = "{format_source} ";
|
|
||||||
"format-source" = "{volume}% ";
|
|
||||||
"format-source-muted" = " ";
|
"format-source-muted" = " ";
|
||||||
"tooltip" = false;
|
"tooltip" = false;
|
||||||
};
|
};
|
||||||
"sway/mode" = {
|
"sway/mode" = {
|
||||||
"format" = "<span style=\"italic\">{}</span>";
|
"format" = "<span style=\"italic\">{}</span>";
|
||||||
};
|
};
|
||||||
"sway/workspace" = {
|
"sway/workspace" = {
|
||||||
"disable-scroll" = true;
|
"disable-scroll" = true;
|
||||||
};
|
};
|
||||||
"temperature" = {
|
"temperature" = {
|
||||||
"critical-threshold" = 80;
|
"critical-threshold" = 80;
|
||||||
"format" = " {temperatureC}°C ";
|
"format" = "{temperatureC}°C ";
|
||||||
"thermal-zone" =
|
"thermal-zone" = mkIf ( cfg.waybar.cpuThermal.thermalZone != "" )
|
||||||
mkIf (cfg.waybar.cpuThermal.thermalZone != null)
|
"${cfg.waybar.cpuThermal.thermalZone}";
|
||||||
cfg.waybar.cpuThermal.thermalZone;
|
"hwmon-path-abs" = mkIf ( cfg.waybar.cpuThermal.hwmonPathAbs != "" )
|
||||||
"hwmon-path-abs" =
|
|
||||||
mkIf (cfg.waybar.cpuThermal.hwmonPathAbs != "")
|
|
||||||
"${cfg.waybar.cpuThermal.hwmonPathAbs}";
|
"${cfg.waybar.cpuThermal.hwmonPathAbs}";
|
||||||
"input-filename" =
|
"input-filename" = mkIf ( cfg.waybar.cpuThermal.inputFilename != "" )
|
||||||
mkIf (cfg.waybar.cpuThermal.inputFilename != "")
|
|
||||||
"${cfg.waybar.cpuThermal.inputFilename}";
|
"${cfg.waybar.cpuThermal.inputFilename}";
|
||||||
};
|
};
|
||||||
"temperature#gpu" = {
|
"temperature#gpu" = {
|
||||||
|
@ -216,7 +170,121 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
style = builtins.readFile ./files/waybar-style.css;
|
style = ''
|
||||||
|
@define-color color-base-bg #323232;
|
||||||
|
@define-color color-base-fg #ddd;
|
||||||
|
|
||||||
|
@define-color color-hover #f268b3;
|
||||||
|
@define-color color-selected #1cd180;
|
||||||
|
|
||||||
|
@define-color color-ok #1cd180;
|
||||||
|
@define-color color-warning #f2b768;
|
||||||
|
@define-color color-critical #f268b3;
|
||||||
|
|
||||||
|
* {
|
||||||
|
border: none;
|
||||||
|
border-radius: 0;
|
||||||
|
min-height:0;
|
||||||
|
}
|
||||||
|
|
||||||
|
window#waybar {
|
||||||
|
background: @color-base-bg ;
|
||||||
|
color: @color-base-fg;
|
||||||
|
font-family: "Fira Code Nerd Font";
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
|
||||||
|
button,
|
||||||
|
button:disabled,label:disabled{
|
||||||
|
color:inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
button:hover{
|
||||||
|
background:none;
|
||||||
|
box-shadow:inherit;
|
||||||
|
box-shadow:inherit;
|
||||||
|
text-shadow:inherit;
|
||||||
|
text-shadow:inherit;
|
||||||
|
border-top:none;
|
||||||
|
}
|
||||||
|
#workspaces {
|
||||||
|
color:#fff;
|
||||||
|
}
|
||||||
|
#workspaces button {
|
||||||
|
margin:0 3px;
|
||||||
|
padding:4px 4px;
|
||||||
|
color:#9c9c9c;
|
||||||
|
border-bottom: 1px solid transparent;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button:hover {
|
||||||
|
box-shadow:inherit;
|
||||||
|
text-shadow:inherit;
|
||||||
|
color: @color-hover;
|
||||||
|
border-bottom: 1px solid @color-hover;
|
||||||
|
}
|
||||||
|
|
||||||
|
#workspaces button.focused {
|
||||||
|
background: @color-selected;
|
||||||
|
color: @color-base-bg;
|
||||||
|
}
|
||||||
|
#workspaces button.visible:not(.focused) {
|
||||||
|
color: @color-selected;
|
||||||
|
border-color: @color-selected;
|
||||||
|
}
|
||||||
|
|
||||||
|
#clock,
|
||||||
|
#cpu,
|
||||||
|
#memory,
|
||||||
|
#backlight,
|
||||||
|
#network,
|
||||||
|
#tray,
|
||||||
|
#mode,
|
||||||
|
#battery,
|
||||||
|
#idle_inhibitor {
|
||||||
|
padding: 2px 4px;
|
||||||
|
margin: 0;
|
||||||
|
background-color: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
|
#mode{
|
||||||
|
background:@color-warning;
|
||||||
|
font-weight:bold;
|
||||||
|
}
|
||||||
|
#pulseaudio {}
|
||||||
|
#pulseaudio.muted {
|
||||||
|
color:@color-critical;
|
||||||
|
}
|
||||||
|
|
||||||
|
#battery.discharging {
|
||||||
|
color: @color-base-fg;
|
||||||
|
border-bottom: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#battery.charging, #battery.plugged {
|
||||||
|
border-bottom: 1px solid @color-ok;
|
||||||
|
color: @color-selected;
|
||||||
|
}
|
||||||
|
|
||||||
|
#battery.critical:not(.charging),
|
||||||
|
#cpu.critical,
|
||||||
|
#memory.critical{
|
||||||
|
border-color: @color-critical;
|
||||||
|
color: @color-critical;
|
||||||
|
}
|
||||||
|
|
||||||
|
#battery.warning:not(.charging),
|
||||||
|
#cpu.warning,
|
||||||
|
#memory.warning{
|
||||||
|
border-color: @color-warning;
|
||||||
|
color: @color-warning;
|
||||||
|
}
|
||||||
|
|
||||||
|
#tray {
|
||||||
|
font-family: "DejaVu sans";
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,18 +1,15 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.gaming.lutris;
|
cfg = config.modules.gaming.lutris;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.gaming.lutris = {
|
options.modules.gaming.lutris = {
|
||||||
enable = mkEnableOption "enable Lutris Gaming preservation platform";
|
enable = mkEnableOption "enable Lutris Gaming preservation platform";
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
(lutris.override {
|
( lutris.override {
|
||||||
extraLibraries = pkgs: [
|
extraLibraries = pkgs: [
|
||||||
wine
|
wine
|
||||||
xorg.libXcursor
|
xorg.libXcursor
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
{
|
{ pkgs, lib, config, ... }:
|
||||||
pkgs,
|
with lib;
|
||||||
lib,
|
let
|
||||||
config,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.video.kdenlive;
|
cfg = config.modules.video.kdenlive;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.video.kdenlive = {
|
options.modules.video.kdenlive = {
|
||||||
enable = mkEnableOption "enable Kdenlive video editor";
|
enable = mkEnableOption "enable Kdenlive video editor";
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,11 +1,9 @@
|
||||||
{
|
{ lib, config, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.video.mpv;
|
cfg = config.modules.video.mpv;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.video.mpv = {
|
options.modules.video.mpv = {
|
||||||
enable = mkEnableOption "enable MPV video player";
|
enable = mkEnableOption "enable MPV video player";
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
# DNS over HTTP (DoH), aka. Trusted Recursive Resolver (TRR)
|
# DNS over HTTP (DoH), aka. Trusted Recursive Resolver (TRR)
|
||||||
# (https://wiki.mozilla.org/Trusted_Recursive_Resolver), uses a server run by
|
# (https://wiki.mozilla.org/Trusted_Recursive_Resolver), uses a server run by
|
||||||
# Cloudflare to resolve hostnames, even when the system uses another (normal) DNS
|
# Cloudflare to resolve hostnames, even when the system uses another (normal) DNS
|
||||||
# server. This setting disables it and sets the mode to explicit opt-out (5).
|
# server. This setting disables it and sets the mode to explicit opt-out (5).
|
||||||
"network.trr.mode" = 5;
|
"network.trr.mode" = 5;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
{
|
{
|
||||||
# Disables playback of DRM-controlled HTML5 content
|
# Disables playback of DRM-controlled HTML5 content
|
||||||
# if enabled, automatically downloads the Widevine Content Decryption Module
|
# if enabled, automatically downloads the Widevine Content Decryption Module
|
||||||
# provided by Google Inc. Details
|
# provided by Google Inc. Details
|
||||||
# (https://support.mozilla.org/en-US/kb/enable-drm#w_opt-out-of-cdm-playback-uninstall-cdms-and-stop-all-cdm-downloads)
|
# (https://support.mozilla.org/en-US/kb/enable-drm#w_opt-out-of-cdm-playback-uninstall-cdms-and-stop-all-cdm-downloads)
|
||||||
"media.eme.enabled" = false;
|
"media.eme.enabled" = false;
|
||||||
|
|
||||||
# Disables the Widevine Content Decryption Module provided by Google Inc.
|
# Disables the Widevine Content Decryption Module provided by Google Inc.
|
||||||
# Used for the playback of DRM-controlled HTML5 content Details
|
# Used for the playback of DRM-controlled HTML5 content Details
|
||||||
# (https://support.mozilla.org/en-US/kb/enable-drm#w_disable-the-google-widevine-cdm-without-uninstalling)
|
# (https://support.mozilla.org/en-US/kb/enable-drm#w_disable-the-google-widevine-cdm-without-uninstalling)
|
||||||
"media.gmp-widevinecdm.enabled" = false;
|
"media.gmp-widevinecdm.enabled" = false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,17 +1,18 @@
|
||||||
{
|
{
|
||||||
# Disable shield studies
|
|
||||||
# Mozilla shield studies (https://wiki.mozilla.org/Firefox/Shield) is a feature
|
# Disable shield studies
|
||||||
# which allows mozilla to remotely install experimental addons.
|
# Mozilla shield studies (https://wiki.mozilla.org/Firefox/Shield) is a feature
|
||||||
|
# which allows mozilla to remotely install experimental addons.
|
||||||
"app.normandy.enabled" = false;
|
"app.normandy.enabled" = false;
|
||||||
"app.normandy.api_url" = "";
|
"app.normandy.api_url" = "";
|
||||||
"app.shield.optoutstudies.enabled" = false;
|
"app.shield.optoutstudies.enabled" = false;
|
||||||
"extensions.shield-recipe-client.enabled" = false;
|
"extensions.shield-recipe-client.enabled" = false;
|
||||||
"extensions.shield-recipe-client.api_url" = "";
|
"extensions.shield-recipe-client.api_url" = "";
|
||||||
|
|
||||||
# Disable experiments
|
# Disable experiments
|
||||||
# Telemetry Experiments (https://wiki.mozilla.org/Telemetry/Experiments) is a
|
# Telemetry Experiments (https://wiki.mozilla.org/Telemetry/Experiments) is a
|
||||||
# feature that allows Firefox to automatically download and run specially-designed
|
# feature that allows Firefox to automatically download and run specially-designed
|
||||||
# restartless addons based on certain conditions.
|
# restartless addons based on certain conditions.
|
||||||
"experiments.enabled" = false;
|
"experiments.enabled" = false;
|
||||||
"experiments.manifest.uri" = "";
|
"experiments.manifest.uri" = "";
|
||||||
"experiments.supported" = false;
|
"experiments.supported" = false;
|
||||||
|
|
|
@ -1,24 +1,24 @@
|
||||||
{
|
{
|
||||||
# Firefox sends data about installed addons as metadata updates
|
# Firefox sends data about installed addons as metadata updates
|
||||||
# (https://blog.mozilla.org/addons/how-to-opt-out-of-add-on-metadata-updates/), so
|
# (https://blog.mozilla.org/addons/how-to-opt-out-of-add-on-metadata-updates/), so
|
||||||
# Mozilla is able to recommend you other addons.
|
# Mozilla is able to recommend you other addons.
|
||||||
"extensions.getAddons.cache.enabled" = false;
|
"extensions.getAddons.cache.enabled" = false;
|
||||||
|
|
||||||
# Disable about:addons' Get Add-ons panel
|
# Disable about:addons' Get Add-ons panel
|
||||||
# The start page with recommended addons uses google analytics.
|
# The start page with recommended addons uses google analytics.
|
||||||
"extensions.getAddons.showPane" = false;
|
"extensions.getAddons.showPane" = false;
|
||||||
"extensions.webservice.discoverURL" = "";
|
"extensions.webservice.discoverURL" = "";
|
||||||
|
|
||||||
# disable pocket extension
|
# disable pocket extension
|
||||||
"extensions.pocket.enabled" = false;
|
"extensions.pocket.enabled" = false;
|
||||||
|
|
||||||
# disable extensions recommendations
|
# disable extensions recommendations
|
||||||
"extensions.htmlaboutaddons.recommendations.enabled" = false;
|
"extensions.htmlaboutaddons.recommendations.enabled" = false;
|
||||||
|
|
||||||
# Automatically activate extensions
|
# Automatically activate extensions
|
||||||
"extensions.autoDisableScopes" = 0;
|
"extensions.autoDisableScopes" = 0;
|
||||||
|
|
||||||
# Deacticate extensions auto-update
|
# Deacticate extensions auto-update
|
||||||
"extensions.update.enabled" = false;
|
"extensions.update.enabled" = false;
|
||||||
"extensions.update.autoUpdateDefault" = false;
|
"extensions.update.autoUpdateDefault" = false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,50 +1,53 @@
|
||||||
{
|
{
|
||||||
|
|
||||||
"browser.sessionstore.enabled" = true;
|
"browser.sessionstore.enabled" = true;
|
||||||
"browser.sessionstore.restore_hidden_tabs" = true;
|
"browser.sessionstore.restore_hidden_tabs" = true;
|
||||||
"browser.sessionstore.restore_pinned_tabs_on_demand" = true;
|
"browser.sessionstore.restore_pinned_tabs_on_demand" = true;
|
||||||
"browser.sessionstore.resume_after_os_start" = true;
|
"browser.sessionstore.resume_after_os_start" = true;
|
||||||
|
|
||||||
# use blank page for new tabs
|
# use blank page for new tabs
|
||||||
"browser.newtabpage.enabled" = false;
|
"browser.newtabpage.enabled" = false;
|
||||||
|
|
||||||
# Disable preloading of the new tab page.
|
# Disable preloading of the new tab page.
|
||||||
# By default Firefox preloads the new tab page (with website thumbnails) in the
|
# By default Firefox preloads the new tab page (with website thumbnails) in the
|
||||||
# background before it is even opened.
|
# background before it is even opened.
|
||||||
"browser.newtab.preload" = false;
|
"browser.newtab.preload" = false;
|
||||||
|
|
||||||
# Disable check for captive portal.
|
|
||||||
# By default, Firefox checks for the presence of a captive portal on every
|
# Disable check for captive portal.
|
||||||
# startup. This involves traffic to Akamai
|
# By default, Firefox checks for the presence of a captive portal on every
|
||||||
# (https://support.mozilla.org/questions/1169302).
|
# startup. This involves traffic to Akamai
|
||||||
|
# (https://support.mozilla.org/questions/1169302).
|
||||||
"network.captive-portal-service.enabled" = false;
|
"network.captive-portal-service.enabled" = false;
|
||||||
|
|
||||||
# Disable Javascript in PDF viewer
|
|
||||||
# Disables executing of JavaScript in the PDF form viewer. It is possible that
|
# Disable Javascript in PDF viewer
|
||||||
# some PDFs are not rendered correctly due to missing functions.
|
# Disables executing of JavaScript in the PDF form viewer. It is possible that
|
||||||
|
# some PDFs are not rendered correctly due to missing functions.
|
||||||
"pdfjs.enableScripting" = true;
|
"pdfjs.enableScripting" = true;
|
||||||
|
|
||||||
# Allow fullscreen in Firefox windows
|
# Allow fullscreen in Firefox windows
|
||||||
"full-screen-api.ignore-widgets" = true;
|
"full-screen-api.ignore-widgets" = true;
|
||||||
|
|
||||||
# About:config show warning
|
# About:config show warning
|
||||||
"browser.aboutConfig.showWarning" = false;
|
"browser.aboutConfig.showWarning" = false;
|
||||||
|
|
||||||
# avoid some useless recommendations
|
# avoid some useless recommendations
|
||||||
"extensions.htmlaboutaddons.recommendations.enabled" = false;
|
"extensions.htmlaboutaddons.recommendations.enabled" = false;
|
||||||
"extensions.recommendations.themeRecommendationUrl" = "";
|
"extensions.recommendations.themeRecommendationUrl" = "";
|
||||||
|
|
||||||
# Do not send FF build ID for site in startup page
|
# Do not send FF build ID for site in startup page
|
||||||
"browser.startup.homepage_override.mstone" = "ignore";
|
"browser.startup.homepage_override.mstone" = "ignore";
|
||||||
|
|
||||||
"browser.aboutHomeSnippets.updateUrl" = "";
|
"browser.aboutHomeSnippets.updateUrl" = "";
|
||||||
|
|
||||||
# Restore session when restart
|
# Restore session when restart
|
||||||
"browser.sessionstore.resume_session_once" = true;
|
"browser.sessionstore.resume_session_once" = true;
|
||||||
|
|
||||||
# Disable translation
|
# Disable translation
|
||||||
"browser.translations.enabled" = false;
|
"browser.translations.enabled" = false;
|
||||||
|
|
||||||
# disable AI shit
|
# disable AI shit
|
||||||
"browser.ml.chat.enabled" = false;
|
"browser.ml.chat.enabled" = false;
|
||||||
"browser.ml.chat.shortcuts" = false;
|
"browser.ml.chat.shortcuts" = false;
|
||||||
"browser.ml.chat.sidebar" = false;
|
"browser.ml.chat.sidebar" = false;
|
||||||
|
|
|
@ -1,107 +1,108 @@
|
||||||
{
|
{
|
||||||
# Disable access to device sensor data
|
# Disable access to device sensor data
|
||||||
# Disallow websites to access sensor data (ambient light, motion, device
|
# Disallow websites to access sensor data (ambient light, motion, device
|
||||||
# orientation and proximity data).
|
# orientation and proximity data).
|
||||||
"device.sensors.ambientLight.enabled" = false;
|
"device.sensors.ambientLight.enabled" = false;
|
||||||
"device.sensors.enabled" = false;
|
"device.sensors.enabled" = false;
|
||||||
"device.sensors.motion.enabled" = false;
|
"device.sensors.motion.enabled" = false;
|
||||||
"device.sensors.orientation.enabled" = false;
|
"device.sensors.orientation.enabled" = false;
|
||||||
"device.sensors.proximity.enabled" = false;
|
"device.sensors.proximity.enabled" = false;
|
||||||
|
|
||||||
# Using a popular useragent string
|
# Using a popular useragent string
|
||||||
# (https://techblog.willshouse.com/2012/01/03/most-common-user-agents/) avoids
|
# (https://techblog.willshouse.com/2012/01/03/most-common-user-agents/) avoids
|
||||||
# attracting attention i.e. with an Iceweasel UA. (keep blank to use the default)
|
# attracting attention i.e. with an Iceweasel UA. (keep blank to use the default)
|
||||||
|
|
||||||
# Block Cookies
|
# Block Cookies
|
||||||
# Block 3rd-Party cookies or even all cookies.
|
# Block 3rd-Party cookies or even all cookies.
|
||||||
"network.cookie.cookieBehavior" = 5;
|
"network.cookie.cookieBehavior" = 5;
|
||||||
|
|
||||||
# Block Referer
|
# Block Referer
|
||||||
# Firefox tells a website, from which site you're coming (the so called RefControl
|
# Firefox tells a website, from which site you're coming (the so called RefControl
|
||||||
# (http://kb.mozillazine.org/Network.http.sendRefererHeader">referer</a>). You can
|
# (http://kb.mozillazine.org/Network.http.sendRefererHeader">referer</a>). You can
|
||||||
# find more detailed settings in this <a
|
# find more detailed settings in this <a
|
||||||
# href="http://www.ghacks.net/2015/01/22/improve-online-privacy-by-controlling-referrer-information/">ghacks
|
# href="http://www.ghacks.net/2015/01/22/improve-online-privacy-by-controlling-referrer-information/">ghacks
|
||||||
# article</a> or install the <a
|
# article</a> or install the <a
|
||||||
# href="https://addons.mozilla.org/firefox/addon/refcontrol/) extension for per
|
# href="https://addons.mozilla.org/firefox/addon/refcontrol/) extension for per
|
||||||
# domain settings.
|
# domain settings.
|
||||||
"network.http.referer.spoofSource" = true;
|
"network.http.referer.spoofSource" = true;
|
||||||
|
|
||||||
# Disable DOM storage
|
# Disable DOM storage
|
||||||
# Disables DOM storage, which enables so called "supercookies". Some modern sites
|
# Disables DOM storage, which enables so called "supercookies". Some modern sites
|
||||||
# will not work (i.e. missing "save" functions).
|
# will not work (i.e. missing "save" functions).
|
||||||
"dom.storage.enabled" = true;
|
"dom.storage.enabled" = true;
|
||||||
|
|
||||||
# Disable IndexedDB (breaks things)
|
# Disable IndexedDB (breaks things)
|
||||||
# abused for tracking (http://www.w3.org/TR/IndexedDB/">IndexedDB</a> is a way,
|
# abused for tracking (http://www.w3.org/TR/IndexedDB/">IndexedDB</a> is a way,
|
||||||
# websites can store structured data. This can be <a
|
# websites can store structured data. This can be <a
|
||||||
# href="http://arstechnica.com/apple/2010/09/rldguid-tracking-cookies-in-safari-database-form/),
|
# href="http://arstechnica.com/apple/2010/09/rldguid-tracking-cookies-in-safari-database-form/),
|
||||||
# too. Disabling causes problems when sites depend on it like Tweetdeck or Reddit
|
# too. Disabling causes problems when sites depend on it like Tweetdeck or Reddit
|
||||||
# and extensions that use it to store their data. Some users reported crashing
|
# and extensions that use it to store their data. Some users reported crashing
|
||||||
# tabs when IndexedDB is disabled. Only disable it, when you know what you're
|
# tabs when IndexedDB is disabled. Only disable it, when you know what you're
|
||||||
# doing.
|
# doing.
|
||||||
"dom.indexedDB.enabled" = true;
|
"dom.indexedDB.enabled" = true;
|
||||||
|
|
||||||
# Disable the Offline Cache.
|
# Disable the Offline Cache.
|
||||||
# Websites can store up to 500 MB of data in an offline cache
|
# Websites can store up to 500 MB of data in an offline cache
|
||||||
# (http://kb.mozillazine.org/Browser.cache.offline.enable), to be able to run even
|
# (http://kb.mozillazine.org/Browser.cache.offline.enable), to be able to run even
|
||||||
# when there is no working internet connection. This could possibly be used to
|
# when there is no working internet connection. This could possibly be used to
|
||||||
# store an user id.
|
# store an user id.
|
||||||
"browser.cache.offline.enable" = false;
|
"browser.cache.offline.enable" = false;
|
||||||
|
|
||||||
# Sessionstore Privacy
|
# Sessionstore Privacy
|
||||||
# This preference controls when to store extra information about a session:
|
# This preference controls when to store extra information about a session:
|
||||||
# contents of forms, scrollbar positions, cookies, and POST data.
|
# contents of forms, scrollbar positions, cookies, and POST data.
|
||||||
"browser.sessionstore.privacy_level" = 2;
|
"browser.sessionstore.privacy_level" = 2;
|
||||||
|
|
||||||
# Disable Link Prefetching
|
# Disable Link Prefetching
|
||||||
# Firefox prefetches the next site on some links, so the site is loaded even when
|
# Firefox prefetches the next site on some links, so the site is loaded even when
|
||||||
# you never click.
|
# you never click.
|
||||||
"network.prefetch-next" = false;
|
"network.prefetch-next" = false;
|
||||||
"network.dns.disablePrefetch" = true;
|
"network.dns.disablePrefetch" = true;
|
||||||
"network.dns.disablePrefetchFromHTTPS" = true;
|
"network.dns.disablePrefetchFromHTTPS" = true;
|
||||||
"network.predictor.enabled" = false;
|
"network.predictor.enabled" = false;
|
||||||
"network.predictor.enable-prefetch" = false;
|
"network.predictor.enable-prefetch" = false;
|
||||||
|
|
||||||
# Disable speculative website loading.
|
# Disable speculative website loading.
|
||||||
# In some situations Firefox already starts loading web pages when the mouse
|
# In some situations Firefox already starts loading web pages when the mouse
|
||||||
# pointer is over a link, i. e. before you actually click. This is to speed up the
|
# pointer is over a link, i. e. before you actually click. This is to speed up the
|
||||||
# loading of web pages by a few milliseconds.
|
# loading of web pages by a few milliseconds.
|
||||||
"network.http.speculative-parallel-limit" = 0;
|
"network.http.speculative-parallel-limit" = 0;
|
||||||
"browser.urlbar.speculativeConnect.enabled" = false;
|
"browser.urlbar.speculativeConnect.enabled" = false;
|
||||||
|
|
||||||
# Use a private container for new tab page thumbnails
|
# Use a private container for new tab page thumbnails
|
||||||
# Load the pages displayed on the new tab page in a private container when
|
# Load the pages displayed on the new tab page in a private container when
|
||||||
# creating thumbnails.
|
# creating thumbnails.
|
||||||
"privacy.usercontext.about_newtab_segregation.enabled" = true;
|
"privacy.usercontext.about_newtab_segregation.enabled" = true;
|
||||||
|
|
||||||
# Disable WebGL
|
# Disable WebGL
|
||||||
# Disables the WebGL function, to prevent (ab)use the full power of the graphics
|
# Disables the WebGL function, to prevent (ab)use the full power of the graphics
|
||||||
# card (http://www.uniquemachine.org/">fingerprinting with WebGL</a>. Another
|
# card (http://www.uniquemachine.org/">fingerprinting with WebGL</a>. Another
|
||||||
# issue is, that websites can <a
|
# issue is, that websites can <a
|
||||||
# href="https://isc.sans.edu/forums/diary/Time+to+disable+WebGL/10867). WebGL is
|
# href="https://isc.sans.edu/forums/diary/Time+to+disable+WebGL/10867). WebGL is
|
||||||
# part of some fingerprinting scripts used in the wild. Some interactive websites
|
# part of some fingerprinting scripts used in the wild. Some interactive websites
|
||||||
# will not work, which are mostly games.
|
# will not work, which are mostly games.
|
||||||
"webgl.disabled" = false;
|
"webgl.disabled" = false;
|
||||||
|
|
||||||
# Override graphics card vendor and model strings in the WebGL API
|
# Override graphics card vendor and model strings in the WebGL API
|
||||||
# Websites can read the graphics card vendor and model using a WebGL API. This
|
# Websites can read the graphics card vendor and model using a WebGL API. This
|
||||||
# setting overrides both with " " without disabling WebGL.
|
# setting overrides both with " " without disabling WebGL.
|
||||||
"webgl.renderer-string-override" = " ";
|
"webgl.renderer-string-override" = " ";
|
||||||
"webgl.vendor-string-override" = " ";
|
"webgl.vendor-string-override" = " ";
|
||||||
|
|
||||||
# Disable WebRTC
|
# Disable WebRTC
|
||||||
# Disables the WebRTC function, which gives away your local ips. Some addons like
|
# Disables the WebRTC function, which gives away your local ips. Some addons like
|
||||||
# uBlock origin provide settings to prevent WebRTC from exposing local ips without
|
# uBlock origin provide settings to prevent WebRTC from exposing local ips without
|
||||||
# disabling WebRTC.
|
# disabling WebRTC.
|
||||||
"media.peerconnection.enabled" = true;
|
"media.peerconnection.enabled" = true;
|
||||||
|
|
||||||
# Disable the clipboardevents.
|
# Disable the clipboardevents.
|
||||||
# Disable that websites can get notifications if you copy, paste, or cut something
|
# Disable that websites can get notifications if you copy, paste, or cut something
|
||||||
# from a web page, and it lets them know which part of the page had been selected.
|
# from a web page, and it lets them know which part of the page had been selected.
|
||||||
"dom.event.clipboardevents.enabled" = false;
|
"dom.event.clipboardevents.enabled" = false;
|
||||||
|
|
||||||
# Disable Fixup URLs
|
# Disable Fixup URLs
|
||||||
# When you type "something" in the urlbar and press enter, Firefox tries
|
# When you type "something" in the urlbar and press enter, Firefox tries
|
||||||
# "something.com", if Fixup URLs is enabled.
|
# "something.com", if Fixup URLs is enabled.
|
||||||
"browser.fixup.alternate.enabled" = false;
|
"browser.fixup.alternate.enabled" = false;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
{
|
{
|
||||||
# Disable google safebrowsing
|
# Disable google safebrowsing
|
||||||
# Google safebrowsing can detect phishing and malware but it also sends
|
# Google safebrowsing can detect phishing and malware but it also sends
|
||||||
# information to google together with an unique id called wrkey
|
# informations to google together with an unique id called wrkey
|
||||||
# (http://electroholiker.de/?p=1594).
|
# (http://electroholiker.de/?p=1594).
|
||||||
"browser.safebrowsing.enabled" = false;
|
"browser.safebrowsing.enabled" = false;
|
||||||
"browser.safebrowsing.downloads.remote.url" = "";
|
"browser.safebrowsing.downloads.remote.url" = "";
|
||||||
"browser.safebrowsing.phishing.enabled" = false;
|
"browser.safebrowsing.phishing.enabled" = false;
|
||||||
|
|
|
@ -1,10 +1,11 @@
|
||||||
{
|
{
|
||||||
# Disable Firefox Suggest
|
|
||||||
# The Firefox Suggest
|
# Disable Firefox Suggest
|
||||||
# (https://support.mozilla.org/en-US/kb/navigate-web-faster-firefox-suggest)
|
# The Firefox Suggest
|
||||||
# feature allows Mozilla to provide search suggestions in the US, which uses your
|
# (https://support.mozilla.org/en-US/kb/navigate-web-faster-firefox-suggest)
|
||||||
# city location and search keywords to send suggestions. This is also used to
|
# feature allows Mozilla to provide search suggestions in the US, which uses your
|
||||||
# serve advertisements.
|
# city location and search keywords to send suggestions. This is also used to
|
||||||
|
# serve advertisements.
|
||||||
"browser.urlbar.groupLabels.enabled" = false;
|
"browser.urlbar.groupLabels.enabled" = false;
|
||||||
"browser.urlbar.quicksuggest.enabled" = false;
|
"browser.urlbar.quicksuggest.enabled" = false;
|
||||||
"browser.urlbar.suggest.addons" = false;
|
"browser.urlbar.suggest.addons" = false;
|
||||||
|
@ -16,9 +17,9 @@
|
||||||
"browser.urlbar.suggest.searches" = false;
|
"browser.urlbar.suggest.searches" = false;
|
||||||
"browser.urlbar.suggest.topsites" = false;
|
"browser.urlbar.suggest.topsites" = false;
|
||||||
|
|
||||||
# Enable Search Keyword
|
# Enable Search Keyword
|
||||||
# When you mistype some url, Firefox starts a search even from urlbar. This
|
# When you mistype some url, Firefox starts a search even from urlbar. This
|
||||||
# feature is useful for quick searching, but may harm your privacy, when it's
|
# feature is useful for quick searching, but may harm your privacy, when it's
|
||||||
# unintended.
|
# unintended.
|
||||||
"keyword.enabled" = true;
|
"keyword.enabled" = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,8 +1,9 @@
|
||||||
{
|
{
|
||||||
# Disable Telemetry
|
|
||||||
# The telemetry feature
|
# Disable Telemetry
|
||||||
# (https://support.mozilla.org/kb/share-telemetry-data-mozilla-help-improve-firefox)
|
# The telemetry feature
|
||||||
# sends data about the performance and responsiveness of Firefox to Mozilla.
|
# (https://support.mozilla.org/kb/share-telemetry-data-mozilla-help-improve-firefox)
|
||||||
|
# sends data about the performance and responsiveness of Firefox to Mozilla.
|
||||||
"toolkit.telemetry.enabled" = false;
|
"toolkit.telemetry.enabled" = false;
|
||||||
"toolkit.telemetry.archive.enabled" = false;
|
"toolkit.telemetry.archive.enabled" = false;
|
||||||
"toolkit.telemetry.rejected" = true;
|
"toolkit.telemetry.rejected" = true;
|
||||||
|
@ -19,19 +20,20 @@
|
||||||
"toolkit.telemetry.hybridContent.enabled" = false;
|
"toolkit.telemetry.hybridContent.enabled" = false;
|
||||||
"toolkit.telemetry.reportingpolicy.firstRun" = false;
|
"toolkit.telemetry.reportingpolicy.firstRun" = false;
|
||||||
|
|
||||||
# Disable health report
|
# Disable health report
|
||||||
# Disable sending Firefox health reports
|
# Disable sending Firefox health reports
|
||||||
# (https://www.mozilla.org/privacy/firefox/#health-report) to Mozilla
|
# (https://www.mozilla.org/privacy/firefox/#health-report) to Mozilla
|
||||||
"datareporting.healthreport.uploadEnabled" = false;
|
"datareporting.healthreport.uploadEnabled" = false;
|
||||||
"datareporting.policy.dataSubmissionEnabled" = false;
|
"datareporting.policy.dataSubmissionEnabled" = false;
|
||||||
"datareporting.healthreport.service.enabled" = false;
|
"datareporting.healthreport.service.enabled" = false;
|
||||||
|
|
||||||
# Disable Crash Reports
|
# Disable Crash Reports
|
||||||
# The crash report (https://www.mozilla.org/privacy/firefox/#crash-reporter) may
|
# The crash report (https://www.mozilla.org/privacy/firefox/#crash-reporter) may
|
||||||
# contain data that identifies you or is otherwise sensitive to you.
|
# contain data that identifies you or is otherwise sensitive to you.
|
||||||
"breakpad.reportURL" = "";
|
"breakpad.reportURL" = "";
|
||||||
"browser.tabs.crashReporting.sendReport" = false;
|
"browser.tabs.crashReporting.sendReport" = false;
|
||||||
"browser.crashReports.unsubmittedCheck.enabled" = false;
|
"browser.crashReports.unsubmittedCheck.enabled" = false;
|
||||||
"browser.crashReports.unsubmittedCheck.autoSubmit" = false;
|
"browser.crashReports.unsubmittedCheck.autoSubmit" = false;
|
||||||
"browser.crashReports.unsubmittedCheck.autoSubmit2" = false;
|
"browser.crashReports.unsubmittedCheck.autoSubmit2" = false;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
"extensions.activeThemeID" = "firefox-compact-dark@mozilla.org";
|
"extensions.activeThemeID" = "firefox-compact-dark@mozilla.org";
|
||||||
"browser.uidensity" = 1;
|
"browser.uidensity" = 1;
|
||||||
|
|
||||||
# New tab behaviour
|
# New tab behaviour
|
||||||
"browser.newtabpage.activity-stream.showSearch" = false;
|
"browser.newtabpage.activity-stream.showSearch" = false;
|
||||||
"browser.newtabpage.activity-stream.feeds.topsites" = false;
|
"browser.newtabpage.activity-stream.feeds.topsites" = false;
|
||||||
"browser.newtabpage.activity-stream.feeds.section.highlights" = false;
|
"browser.newtabpage.activity-stream.feeds.section.highlights" = false;
|
||||||
|
@ -11,30 +11,30 @@
|
||||||
"browser.newtabpage.activity-stream.showSponsoredTopSites" = false;
|
"browser.newtabpage.activity-stream.showSponsoredTopSites" = false;
|
||||||
"browser.newtabpage.activity-stream.showSponsored" = false;
|
"browser.newtabpage.activity-stream.showSponsored" = false;
|
||||||
|
|
||||||
# Mozilla messages and recommendations
|
# Mozilla messages and recommendations
|
||||||
"browser.messaging-system.whatsNewPanel.enabled" = false;
|
"browser.messaging-system.whatsNewPanel.enabled" = false;
|
||||||
"browser.newtabpage.activity-stream.asrouter.userprefs.cfr.addons" = false;
|
"browser.newtabpage.activity-stream.asrouter.userprefs.cfr.addons" = false;
|
||||||
"browser.newtabpage.activity-stream.asrouter.userprefs.cfr.features" = false;
|
"browser.newtabpage.activity-stream.asrouter.userprefs.cfr.features" = false;
|
||||||
"browser.aboutwelcome.enabled" = false;
|
"browser.aboutwelcome.enabled" = false;
|
||||||
"browser.preferences.moreFromMozilla" = false;
|
"browser.preferences.moreFromMozilla" = false;
|
||||||
|
|
||||||
# Do not save my logins
|
# Do not save my logins
|
||||||
"signon.rememberSignons" = false;
|
"signon.rememberSignons" = false;
|
||||||
|
|
||||||
# do not override status page
|
# do not override status page
|
||||||
"startup.homepage_override_url" = "";
|
"startup.homepage_override_url" = "";
|
||||||
"startup.homepage_welcome_url" = "";
|
"startup.homepage_welcome_url" = "";
|
||||||
|
|
||||||
# do not show bookmark page
|
# do not show bookmark page
|
||||||
"browser.toolbars.bookmarks.visibility" = "never";
|
"browser.toolbars.bookmarks.visibility" = "never";
|
||||||
|
|
||||||
# disable fucking included malwares
|
# disable fucking included malwares
|
||||||
"browser.newtabpage.activity-stream.improvesearch.topSiteSearchShortcuts.havePinned" = "";
|
"browser.newtabpage.activity-stream.improvesearch.topSiteSearchShortcuts.havePinned" = "";
|
||||||
"browser.newtabpage.activity-stream.improvesearch.topSiteSearchShortcuts.searchEngines" = "";
|
"browser.newtabpage.activity-stream.improvesearch.topSiteSearchShortcuts.searchEngines" = "";
|
||||||
"browser.newtabpage.activity-stream.improvesearch.topSiteSearchShortcuts" = false;
|
"browser.newtabpage.activity-stream.improvesearch.topSiteSearchShortcuts" = false;
|
||||||
"browser.newtabpage.pinned" = "";
|
"browser.newtabpage.pinned" = "";
|
||||||
|
|
||||||
# Theme customization
|
# Theme customization
|
||||||
"browser.uiCustomization.state" = builtins.toJSON {
|
"browser.uiCustomization.state" = builtins.toJSON {
|
||||||
currentVersion = 20;
|
currentVersion = 20;
|
||||||
newElementCount = 4;
|
newElementCount = 4;
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
{
|
{
|
||||||
# Enable Do-not-Track
|
|
||||||
|
# Enable Do-not-Track
|
||||||
# With the do not track feature, you tell websites, that you do not want to be
|
# With the do not track feature, you tell websites, that you do not want to be
|
||||||
# tracked. Most websites ignore this, so you need other privacy options as well.
|
# tracked. Most websites ignore this, so you need other privacy options as well.
|
||||||
"privacy.donottrackheader.enabled" = true;
|
"privacy.donottrackheader.enabled" = true;
|
||||||
|
|
|
@ -1,28 +1,25 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
merge = foldr (a: b: a // b) { };
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
merge = foldr (a: b: a // b) {};
|
|
||||||
cfg = config.modules.web.firefox;
|
cfg = config.modules.web.firefox;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.web.firefox = {
|
options.modules.web.firefox = {
|
||||||
enable = mkEnableOption "enable Firefox web browser";
|
enable = mkEnableOption "enable Firefox web browser";
|
||||||
|
|
||||||
baseExtensions = mkOption {
|
baseExtensions = mkOption {
|
||||||
type = types.listOf types.package;
|
type = types.listOf types.package;
|
||||||
default = with pkgs.nur.repos.rycee.firefox-addons; [
|
default = with pkgs.nur.repos.rycee.firefox-addons; [
|
||||||
browserpass
|
browserpass
|
||||||
consent-o-matic
|
consent-o-matic
|
||||||
cookie-autodelete
|
cookie-autodelete
|
||||||
darkreader
|
darkreader
|
||||||
decentraleyes
|
decentraleyes
|
||||||
tridactyl
|
tridactyl
|
||||||
ublock-origin
|
ublock-origin
|
||||||
privacy-badger
|
privacy-badger
|
||||||
];
|
];
|
||||||
description = "Base Firefox Plugins to install";
|
description = "Base Firefox Plugins to install";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -31,6 +28,7 @@ in {
|
||||||
default = [];
|
default = [];
|
||||||
description = "Optional Firefox Plugins to install";
|
description = "Optional Firefox Plugins to install";
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
programs.browserpass = {
|
programs.browserpass = {
|
||||||
|
@ -69,10 +67,10 @@ in {
|
||||||
'';
|
'';
|
||||||
|
|
||||||
programs.firefox = let
|
programs.firefox = let
|
||||||
allExtensions = cfg.baseExtensions ++ cfg.optionalExtensions;
|
allExtensions = cfg.baseExtensions ++ cfg.optionalExtensions;
|
||||||
in {
|
in {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = config.lib.nixGL.wrap (pkgs.wrapFirefox pkgs.firefox-unwrapped {
|
package = config.lib.nixGL.wrap ( pkgs.wrapFirefox pkgs.firefox-unwrapped {
|
||||||
nativeMessagingHosts = [
|
nativeMessagingHosts = [
|
||||||
# Tridactyl native connector
|
# Tridactyl native connector
|
||||||
pkgs.tridactyl-native
|
pkgs.tridactyl-native
|
||||||
|
@ -87,32 +85,24 @@ in {
|
||||||
search = {
|
search = {
|
||||||
force = true;
|
force = true;
|
||||||
default = "ddg";
|
default = "ddg";
|
||||||
engines = {
|
engines = {
|
||||||
"Nix Packages" = {
|
"Nix Packages" = {
|
||||||
urls = [
|
urls = [{
|
||||||
{
|
template = "https://search.nixos.org/packages";
|
||||||
template = "https://search.nixos.org/packages";
|
params = [
|
||||||
params = [
|
{ name = "type"; value = "packages"; }
|
||||||
{
|
{ name = "query"; value = "{searchTerms}"; }
|
||||||
name = "type";
|
];
|
||||||
value = "packages";
|
}];
|
||||||
}
|
|
||||||
{
|
|
||||||
name = "query";
|
|
||||||
value = "{searchTerms}";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
||||||
];
|
|
||||||
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
|
icon = "${pkgs.nixos-icons}/share/icons/hicolor/scalable/apps/nix-snowflake.svg";
|
||||||
definedAliases = ["@np"];
|
definedAliases = [ "@np" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
"NixOS Wiki" = {
|
"NixOS Wiki" = {
|
||||||
urls = [{template = "https://nixos.wiki/index.php?search={searchTerms}";}];
|
urls = [{ template = "https://nixos.wiki/index.php?search={searchTerms}"; }];
|
||||||
icon = "https://nixos.wiki/favicon.png";
|
icon = "https://nixos.wiki/favicon.png";
|
||||||
updateInterval = 24 * 60 * 60 * 1000; # every day
|
updateInterval = 24 * 60 * 60 * 1000; # every day
|
||||||
definedAliases = ["@nw"];
|
definedAliases = [ "@nw" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
"bing".metaData.hidden = true;
|
"bing".metaData.hidden = true;
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.web.qutebrowser;
|
cfg = config.modules.web.qutebrowser;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.web.qutebrowser = {
|
options.modules.web.qutebrowser = {
|
||||||
enable = mkEnableOption "enable Qutebrowser web browser";
|
enable = mkEnableOption "enable Qutebrowser web browser";
|
||||||
};
|
};
|
||||||
|
@ -56,7 +53,7 @@ in {
|
||||||
"history"
|
"history"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
extraConfig = (builtins.readFile ./files/theme.py);
|
extraConfig = ( builtins.readFile ./files/theme.py);
|
||||||
keyBindings = {
|
keyBindings = {
|
||||||
normal = {
|
normal = {
|
||||||
",M" = "hint links spawn mpv {hint-url}";
|
",M" = "hint links spawn mpv {hint-url}";
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.web.webcord;
|
cfg = config.modules.web.webcord;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.web.webcord = {
|
options.modules.web.webcord = {
|
||||||
enable = mkEnableOption "enable Lutris Gaming preservation platform";
|
enable = mkEnableOption "enable Lutris Gaming preservation platform";
|
||||||
};
|
};
|
||||||
|
@ -14,7 +11,7 @@ in {
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
webcord
|
webcord
|
||||||
];
|
];
|
||||||
|
|
||||||
xdg.desktopEntries = {
|
xdg.desktopEntries = {
|
||||||
webcord = {
|
webcord = {
|
||||||
name = "Webcord";
|
name = "Webcord";
|
||||||
|
@ -22,7 +19,7 @@ in {
|
||||||
exec = "webcord --ozone-platform=wayland";
|
exec = "webcord --ozone-platform=wayland";
|
||||||
icon = "webcord";
|
icon = "webcord";
|
||||||
terminal = false;
|
terminal = false;
|
||||||
categories = ["Application" "Network" "WebBrowser"];
|
categories = [ "Application" "Network" "WebBrowser" ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
_: {
|
_:
|
||||||
|
{
|
||||||
imports = [
|
imports = [
|
||||||
./desktop/sway
|
./desktop/sway
|
||||||
./gaming/steam
|
./gaming/steam
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
{
|
{ pkgs, lib, config, ... }:
|
||||||
pkgs,
|
with lib;
|
||||||
lib,
|
let
|
||||||
config,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.desktop.sway;
|
cfg = config.modules.desktop.sway;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.desktop.sway = {
|
options.modules.desktop.sway = {
|
||||||
enable = mkEnableOption "Enable Steam Platform";
|
enable = mkEnableOption "Enable Steam Platform";
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,11 +1,9 @@
|
||||||
{
|
{ lib, config, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.gaming.steam;
|
cfg = config.modules.gaming.steam;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.gaming.steam = {
|
options.modules.gaming.steam = {
|
||||||
enable = mkEnableOption "Enable Steam Platform";
|
enable = mkEnableOption "Enable Steam Platform";
|
||||||
|
|
||||||
|
@ -33,8 +31,8 @@ in {
|
||||||
gamescopeSession = {
|
gamescopeSession = {
|
||||||
enable = cfg.gamescope;
|
enable = cfg.gamescope;
|
||||||
args = [
|
args = [
|
||||||
"-O HDMI-A-2"
|
"-O HDMI-A-2"
|
||||||
"-F fsr"
|
"-F fsr"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,16 +1,15 @@
|
||||||
{
|
{ lib, config, pkgs, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.hardware.lact;
|
cfg = config.modules.hardware.lact;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.hardware.lact = {
|
options.modules.hardware.lact = {
|
||||||
enable = mkEnableOption "Install LACT daemon";
|
enable = mkEnableOption "Install LACT daemon";
|
||||||
|
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
|
||||||
# Enable Lact (testing purpose for now)
|
# Enable Lact (testing purpose for now)
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
lact
|
lact
|
||||||
|
|
|
@ -1,11 +1,9 @@
|
||||||
{
|
{ lib, config, ... }:
|
||||||
lib,
|
with lib;
|
||||||
config,
|
let
|
||||||
...
|
|
||||||
}:
|
|
||||||
with lib; let
|
|
||||||
cfg = config.modules.hardware.laptop;
|
cfg = config.modules.hardware.laptop;
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
options.modules.hardware.laptop = {
|
options.modules.hardware.laptop = {
|
||||||
enable = mkEnableOption "Install Laptop utils";
|
enable = mkEnableOption "Install Laptop utils";
|
||||||
|
|
||||||
|
@ -27,6 +25,7 @@ in {
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
|
|
||||||
# Wifi is installed on laptops
|
# Wifi is installed on laptops
|
||||||
networking.wireless.iwd.enable = true;
|
networking.wireless.iwd.enable = true;
|
||||||
|
|
||||||
|
|
|
@ -1,11 +1,6 @@
|
||||||
|
{ pkgs, stateVersion, hostname, ... }:
|
||||||
{
|
{
|
||||||
pkgs,
|
imports = [ # Include the results of the hardware scan.
|
||||||
stateVersion,
|
|
||||||
hostname,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
imports = [
|
|
||||||
# Include the results of the hardware scan.
|
|
||||||
../hosts/${hostname}/hardware-configuration.nix
|
../hosts/${hostname}/hardware-configuration.nix
|
||||||
../hosts/${hostname}/nixos-config.nix
|
../hosts/${hostname}/nixos-config.nix
|
||||||
../modules/nixos
|
../modules/nixos
|
||||||
|
@ -22,7 +17,7 @@
|
||||||
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
|
||||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||||
networking.hostName = hostname;
|
networking.hostName = hostname;
|
||||||
|
|
||||||
console = {
|
console = {
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
{
|
{
|
||||||
hardware.nitrokey.enable = true;
|
hardware.nitrokey.enable = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
{config, ...}: {
|
{ config, ...}:
|
||||||
|
{
|
||||||
security.doas.enable = true;
|
security.doas.enable = true;
|
||||||
security.sudo.enable = false;
|
security.sudo.enable = false;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
{pkgs, ...}: {
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
nix = {
|
nix = {
|
||||||
package = pkgs.nixVersions.latest;
|
package = pkgs.nixVersions.latest;
|
||||||
extraOptions = ''
|
extraOptions = ''
|
||||||
|
@ -6,3 +7,4 @@
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
{config, ...}: {
|
{ config, ... }:
|
||||||
|
{
|
||||||
time.timeZone = "Europe/Paris";
|
time.timeZone = "Europe/Paris";
|
||||||
# English locale with YYY/MM/DD date format
|
# English locale with YYY/MM/DD date format
|
||||||
i18n = {
|
i18n = {
|
||||||
|
|
|
@ -1,9 +1,10 @@
|
||||||
{pkgs, ...}: {
|
{ pkgs, ... }: {
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
lvm2_dmeventd
|
lvm2_dmeventd
|
||||||
];
|
];
|
||||||
|
|
||||||
services.lvm.enable = true;
|
services.lvm.enable = true;
|
||||||
services.lvm.dmeventd.enable = true;
|
services.lvm.dmeventd.enable = true;
|
||||||
services.lvm.boot.thin.enable = true;
|
services.lvm.boot.thin.enable = true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,8 +1,5 @@
|
||||||
{
|
{ config, pkgs, ...}:
|
||||||
config,
|
{
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
neovim
|
neovim
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,16 +1,10 @@
|
||||||
|
{ inputs, pkgs, ...}:
|
||||||
{
|
{
|
||||||
inputs,
|
|
||||||
pkgs,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
nixpkgs.overlays = [
|
nixpkgs.overlays = [
|
||||||
(final: prev: {
|
(final: prev: {
|
||||||
qutebrowser = prev.qutebrowser.override {
|
qutebrowser = prev.qutebrowser.override {
|
||||||
enableWideVine =
|
enableWideVine = if pkgs.system == "x86_64-linux" then true else false;
|
||||||
if pkgs.system == "x86_64-linux"
|
};
|
||||||
then true
|
|
||||||
else false;
|
|
||||||
};
|
|
||||||
})
|
})
|
||||||
inputs.nur.overlays.default
|
inputs.nur.overlays.default
|
||||||
];
|
];
|
||||||
|
|
|
@ -1,8 +1,5 @@
|
||||||
|
{ pkgs, username, ... }:
|
||||||
{
|
{
|
||||||
pkgs,
|
|
||||||
username,
|
|
||||||
...
|
|
||||||
}: {
|
|
||||||
# Services
|
# Services
|
||||||
services.pcscd.enable = true;
|
services.pcscd.enable = true;
|
||||||
|
|
||||||
|
@ -18,7 +15,7 @@
|
||||||
users.users.${username} = {
|
users.users.${username} = {
|
||||||
shell = pkgs.zsh;
|
shell = pkgs.zsh;
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
extraGroups = ["video" "wheel"];
|
extraGroups = [ "video" "wheel" ];
|
||||||
home = "/home/${username}";
|
home = "/home/${username}";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue