guh
This commit is contained in:
parent
2f800e15da
commit
629ef01306
139
flake.lock
139
flake.lock
@ -19,11 +19,11 @@
|
|||||||
"devshell": {
|
"devshell": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1654858401,
|
"lastModified": 1655976588,
|
||||||
"narHash": "sha256-53bw34DtVJ2bnF6WEwy6Tym+qY0pNEiEwARUlvmTZjs=",
|
"narHash": "sha256-VreHyH6ITkf/1EX/8h15UqhddJnUleb0HgbC3gMkAEQ=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "devshell",
|
"repo": "devshell",
|
||||||
"rev": "f55e05c6d3bbe9acc7363bc8fc739518b2f02976",
|
"rev": "899ca4629020592a13a46783587f6e674179d1db",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -82,11 +82,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1655826285,
|
"lastModified": 1655975833,
|
||||||
"narHash": "sha256-dyrNTVBefSZWKdFNnAW+zUkO5bVo1colvLje4l1XXwA=",
|
"narHash": "sha256-g8sdfuglIZ24oWVbntVzniNTJW+Z3n9DNL9w9Tt+UCE=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "dream2nix",
|
"repo": "dream2nix",
|
||||||
"rev": "f23add2b9c313c63dea5cff71523a850d29ffddb",
|
"rev": "4e75e665ec3a1cddae5266bed0dd72fce0b74a23",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -95,22 +95,6 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"flake-compat": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1650374568,
|
|
||||||
"narHash": "sha256-Z+s0J8/r907g149rllvwhb4pKi8Wam5ij0st8PwAh+E=",
|
|
||||||
"owner": "edolstra",
|
|
||||||
"repo": "flake-compat",
|
|
||||||
"rev": "b4a34015c698c7793d592d66adbab377907a2be8",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "edolstra",
|
|
||||||
"repo": "flake-compat",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"flake-utils": {
|
"flake-utils": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1637014545,
|
"lastModified": 1637014545,
|
||||||
@ -135,11 +119,11 @@
|
|||||||
"rust-overlay": "rust-overlay"
|
"rust-overlay": "rust-overlay"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1656263093,
|
"lastModified": 1656581160,
|
||||||
"narHash": "sha256-gYWCKE0XrXB+Sc/MB90XuSTin+R+mlEqG9TIThJ6R18=",
|
"narHash": "sha256-a6jMpUifIin5mK4TvU8iLKm5w5wR34ttbe1l2CdedpY=",
|
||||||
"owner": "helix-editor",
|
"owner": "helix-editor",
|
||||||
"repo": "helix",
|
"repo": "helix",
|
||||||
"rev": "24351c20d41c26df0c695940e6790525858ab1c1",
|
"rev": "d06800f1dd47315f5738c529d40d1e0952ee2115",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -150,20 +134,17 @@
|
|||||||
},
|
},
|
||||||
"home": {
|
"home": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": "flake-compat",
|
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
],
|
],
|
||||||
"nmd": "nmd",
|
|
||||||
"nmt": "nmt",
|
|
||||||
"utils": "utils"
|
"utils": "utils"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1656272360,
|
"lastModified": 1656367977,
|
||||||
"narHash": "sha256-ceFmGObEq5GjObuZ3rI5PUad/OI6yulvsa6mMPciaic=",
|
"narHash": "sha256-0hV17V9Up9pnAtPJ+787FhrsPnawxoTPA/VxgjRMrjc=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "0434f8e4cab4f200c9b4d3741a9e5d89705e6754",
|
"rev": "3bf16c0fd141c28312be52945d1543f9ce557bb1",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -173,6 +154,27 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"hyprland": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
],
|
||||||
|
"wlroots": "wlroots"
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1656612124,
|
||||||
|
"narHash": "sha256-NPiLaoApGbGw3I6Pp4oJnKh/Q64yCSeokLWRWjAmsu4=",
|
||||||
|
"owner": "hyprwm",
|
||||||
|
"repo": "Hyprland",
|
||||||
|
"rev": "4510764f348d1a7c4cca613925ee22acfa38b388",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "hyprwm",
|
||||||
|
"repo": "Hyprland",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"nixCargoIntegration": {
|
"nixCargoIntegration": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"devshell": "devshell",
|
"devshell": "devshell",
|
||||||
@ -187,11 +189,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1655826649,
|
"lastModified": 1656453541,
|
||||||
"narHash": "sha256-C4/7CdB/mzuD9ayWvEA3Jcog6INCq+oUJZxUsIP/GvE=",
|
"narHash": "sha256-ZCPVnS6zJOZJvIlwU3rKR8MBVm6A3F4/0mA7G1lQ3D0=",
|
||||||
"owner": "yusdacra",
|
"owner": "yusdacra",
|
||||||
"repo": "nix-cargo-integration",
|
"repo": "nix-cargo-integration",
|
||||||
"rev": "5cf1685c021c47631a2fb16533c00c8d68afd09e",
|
"rev": "9eb74345b30cd2e536d9dac9d4435d3c475605c7",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -202,11 +204,11 @@
|
|||||||
},
|
},
|
||||||
"nixos-hardware": {
|
"nixos-hardware": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1656241064,
|
"lastModified": 1656353817,
|
||||||
"narHash": "sha256-+jWwBt515aFGukeX8WSafg9CM3Ju3FD0XrF+X4ph0mU=",
|
"narHash": "sha256-UJEzMQcft/0Ilu4LWV7UH51mr5UCo28GL06BGO+djv4=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixos-hardware",
|
"repo": "nixos-hardware",
|
||||||
"rev": "99e33a57149916ebede78ec13edd9ba310c10f2f",
|
"rev": "78e7c2c397b0376526e83162b58de921362e3399",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -232,11 +234,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1656239181,
|
"lastModified": 1656461576,
|
||||||
"narHash": "sha256-wW1xRFBn376yGloXZ4QzBE4hjipMawpV18Lshd9QSPw=",
|
"narHash": "sha256-rlmmw6lIlkMQIiB+NsnO8wQYWTfle8TA41UREPLP5VY=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "f2537a505d45c31fe5d9c27ea9829b6f4c4e6ac5",
|
"rev": "cf3ab54b4afe2b7477faa1dd0b65bf74c055d70c",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -246,45 +248,30 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nmd": {
|
"nur": {
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1653339422,
|
"lastModified": 1656611551,
|
||||||
"narHash": "sha256-RNLq09vfj21TyYuUCeD6BNTNC6Ew8bLhQULZytN4Xx8=",
|
"narHash": "sha256-S1GkwCgMimVVU1nrwezTkoOqsoiXvvK1+pu4zplsqwo=",
|
||||||
"owner": "rycee",
|
"owner": "nix-community",
|
||||||
"repo": "nmd",
|
"repo": "NUR",
|
||||||
"rev": "91dee681dd1c478d6040a00835d73c0f4a4c5c29",
|
"rev": "b58e819d423cc525475b43bd06cf5f999feb5325",
|
||||||
"type": "gitlab"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "rycee",
|
"owner": "nix-community",
|
||||||
"repo": "nmd",
|
"repo": "NUR",
|
||||||
"type": "gitlab"
|
"type": "github"
|
||||||
}
|
|
||||||
},
|
|
||||||
"nmt": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1648075362,
|
|
||||||
"narHash": "sha256-u36WgzoA84dMVsGXzml4wZ5ckGgfnvS0ryzo/3zn/Pc=",
|
|
||||||
"owner": "rycee",
|
|
||||||
"repo": "nmt",
|
|
||||||
"rev": "d83601002c99b78c89ea80e5e6ba21addcfe12ae",
|
|
||||||
"type": "gitlab"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "rycee",
|
|
||||||
"repo": "nmt",
|
|
||||||
"type": "gitlab"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"helix": "helix",
|
"helix": "helix",
|
||||||
"home": "home",
|
"home": "home",
|
||||||
|
"hyprland": "hyprland",
|
||||||
"nixos-hardware": "nixos-hardware",
|
"nixos-hardware": "nixos-hardware",
|
||||||
"nixos-persistence": "nixos-persistence",
|
"nixos-persistence": "nixos-persistence",
|
||||||
"nixpkgs": "nixpkgs",
|
"nixpkgs": "nixpkgs",
|
||||||
|
"nur": "nur",
|
||||||
"smos": "smos"
|
"smos": "smos"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -341,6 +328,24 @@
|
|||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
"wlroots": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"host": "gitlab.freedesktop.org",
|
||||||
|
"lastModified": 1655824477,
|
||||||
|
"narHash": "sha256-1kskHOLsnisR3kqIL5IHrQbQG/4xoXxeEf1ExMV6/RU=",
|
||||||
|
"owner": "wlroots",
|
||||||
|
"repo": "wlroots",
|
||||||
|
"rev": "5c4384a1330faedf975c8b8644881d50390f3613",
|
||||||
|
"type": "gitlab"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"host": "gitlab.freedesktop.org",
|
||||||
|
"owner": "wlroots",
|
||||||
|
"repo": "wlroots",
|
||||||
|
"type": "gitlab"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"root": "root",
|
"root": "root",
|
||||||
|
17
flake.nix
17
flake.nix
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
|
nur.url = "github:nix-community/NUR";
|
||||||
|
|
||||||
home.url = "github:nix-community/home-manager/master";
|
home.url = "github:nix-community/home-manager/master";
|
||||||
home.inputs.nixpkgs.follows = "nixpkgs";
|
home.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
@ -15,6 +16,8 @@
|
|||||||
|
|
||||||
helix.url = "github:helix-editor/helix";
|
helix.url = "github:helix-editor/helix";
|
||||||
helix.inputs.nixpkgs.follows = "nixpkgs";
|
helix.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
hyprland.url = "github:hyprwm/Hyprland";
|
||||||
|
hyprland.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = inputs: let
|
outputs = inputs: let
|
||||||
@ -27,10 +30,22 @@
|
|||||||
};
|
};
|
||||||
genPkgs = f: prev.genSystems (system: f (makePkgs system));
|
genPkgs = f: prev.genSystems (system: f (makePkgs system));
|
||||||
});
|
});
|
||||||
|
allPkgs = tlib.genPkgs (x: x);
|
||||||
in rec {
|
in rec {
|
||||||
nixosConfigurations = import ./hosts {inherit lib tlib inputs;};
|
nixosConfigurations = import ./hosts {inherit lib tlib inputs;};
|
||||||
|
|
||||||
packages = tlib.genPkgs (pkgs: pkgs._exported);
|
packages = lib.mapAttrs (_: pkgs: pkgs._exported) allPkgs;
|
||||||
|
apps =
|
||||||
|
lib.mapAttrs
|
||||||
|
(
|
||||||
|
_: pkgs: {
|
||||||
|
generate-firefox-addons = {
|
||||||
|
type = "app";
|
||||||
|
program = toString "${pkgs.generate-firefox-addons}/bin/generate-firefox-addons";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
)
|
||||||
|
allPkgs;
|
||||||
|
|
||||||
devShells = import ./shells {inherit lib tlib inputs;};
|
devShells = import ./shells {inherit lib tlib inputs;};
|
||||||
};
|
};
|
||||||
|
@ -16,12 +16,15 @@ in {
|
|||||||
common-pc
|
common-pc
|
||||||
common-gpu-amd
|
common-gpu-amd
|
||||||
common-cpu-amd
|
common-cpu-amd
|
||||||
|
../../modules/persist
|
||||||
../../modules/network
|
../../modules/network
|
||||||
#../../modules/develop/nixbuild
|
#../../modules/develop/nixbuild
|
||||||
../../users/root
|
../../users/root
|
||||||
../../users/patriot
|
../../users/patriot
|
||||||
];
|
];
|
||||||
|
|
||||||
|
system.persistDir = "/persist";
|
||||||
|
|
||||||
boot = {
|
boot = {
|
||||||
tmpOnTmpfs = true;
|
tmpOnTmpfs = true;
|
||||||
loader = {
|
loader = {
|
||||||
@ -50,7 +53,7 @@ in {
|
|||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=nix"] ++ btrfsOptions;
|
options = ["subvol=nix"] ++ btrfsOptions;
|
||||||
};
|
};
|
||||||
fileSystems."/persist" = {
|
fileSystems."${config.system.persistDir}" = {
|
||||||
device = btrfsPartPath;
|
device = btrfsPartPath;
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=persist"] ++ btrfsOptions;
|
options = ["subvol=persist"] ++ btrfsOptions;
|
||||||
@ -60,13 +63,6 @@ in {
|
|||||||
device = "/dev/disk/by-label/BOOT";
|
device = "/dev/disk/by-label/BOOT";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
};
|
};
|
||||||
/*
|
|
||||||
fileSystems."/media/archive" = {
|
|
||||||
device = "/dev/disk/by-uuid/f9b5f7f3-51e8-4357-8518-986b16311c71";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = btrfsOptions;
|
|
||||||
};
|
|
||||||
*/
|
|
||||||
|
|
||||||
swapDevices = [];
|
swapDevices = [];
|
||||||
zramSwap = {
|
zramSwap = {
|
||||||
@ -143,7 +139,7 @@ in {
|
|||||||
environment = {
|
environment = {
|
||||||
systemPackages = [pkgs.ntfs3g];
|
systemPackages = [pkgs.ntfs3g];
|
||||||
pathsToLink = ["/share/zsh"];
|
pathsToLink = ["/share/zsh"];
|
||||||
persistence."/persist" = {
|
persistence."${config.system.persistDir}" = {
|
||||||
directories = ["/etc/nixos"];
|
directories = ["/etc/nixos"];
|
||||||
files = ["/etc/machine-id"];
|
files = ["/etc/machine-id"];
|
||||||
};
|
};
|
||||||
|
@ -46,7 +46,6 @@ in {
|
|||||||
exa
|
exa
|
||||||
lm_sensors
|
lm_sensors
|
||||||
mkpasswd
|
mkpasswd
|
||||||
zoxide
|
|
||||||
bottom
|
bottom
|
||||||
amber
|
amber
|
||||||
unzip
|
unzip
|
||||||
|
@ -1,11 +1,9 @@
|
|||||||
{
|
{
|
||||||
imports = [./dns];
|
imports = [./dns];
|
||||||
networking.dhcpcd.enable = false;
|
networking.dhcpcd.enable = true;
|
||||||
networking.useDHCP = false;
|
networking.useDHCP = false;
|
||||||
networking.dhcpcd.extraConfig = ''
|
networking.dhcpcd.extraConfig = ''
|
||||||
noarp
|
noarp
|
||||||
nodelay
|
nodelay
|
||||||
'';
|
'';
|
||||||
# https://github.com/NixOS/nixpkgs/issues/60900
|
|
||||||
# systemd.services.systemd-user-sessions.enable = false;
|
|
||||||
}
|
}
|
||||||
|
5
modules/persist/default.nix
Normal file
5
modules/persist/default.nix
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
{lib, ...}: {
|
||||||
|
options.system.persistDir = lib.mkOption {
|
||||||
|
type = lib.types.str;
|
||||||
|
};
|
||||||
|
}
|
@ -32,9 +32,9 @@
|
|||||||
config.allowUnfree = true;
|
config.allowUnfree = true;
|
||||||
overlays = overlays ++ newPkgs;
|
overlays = overlays ++ newPkgs;
|
||||||
};
|
};
|
||||||
pkgsToExport = import ./pkgs-to-export.nix;
|
pkgsToExport = import ./pkgs-to-export.nix pkgs;
|
||||||
in
|
in
|
||||||
pkgs
|
pkgs
|
||||||
// {
|
// {
|
||||||
_exported = l.getAttrs pkgsToExport pkgs;
|
_exported = pkgsToExport;
|
||||||
}
|
}
|
||||||
|
@ -6,13 +6,8 @@ _: prev: let
|
|||||||
"--enable-gpu-rasterization"
|
"--enable-gpu-rasterization"
|
||||||
"--enable-zero-copy"
|
"--enable-zero-copy"
|
||||||
"--force-dark-mode"
|
"--force-dark-mode"
|
||||||
"--enable-features=VaapiVideoDecoder"
|
|
||||||
"--use-gl=egl"
|
|
||||||
"--disable-features=UseChromeOSDirectVideoDecoder"
|
|
||||||
"--disable-features=UseSkiaRenderer"
|
|
||||||
"--enable-webrtc-pipewire-capturer"
|
"--enable-webrtc-pipewire-capturer"
|
||||||
"--ozone-platform-hint=auto"
|
"--ozone-platform-hint=auto"
|
||||||
"--enable-raw-draw"
|
|
||||||
];
|
];
|
||||||
mkCliArgs = flags: prev.lib.concatStringsSep " " flags;
|
mkCliArgs = flags: prev.lib.concatStringsSep " " flags;
|
||||||
in {
|
in {
|
||||||
|
@ -1,3 +1,3 @@
|
|||||||
{inputs}: final: prev: {
|
{inputs}: final: prev: {
|
||||||
helix = inputs.helix.defaultPackage.${prev.system};
|
helix = inputs.helix.packages.${prev.system}.default;
|
||||||
}
|
}
|
||||||
|
3
pkgs-set/overlays/hyprland.nix
Normal file
3
pkgs-set/overlays/hyprland.nix
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{inputs}: final: prev: {
|
||||||
|
hyprland = inputs.hyprland.packages.${prev.system}.default;
|
||||||
|
}
|
1
pkgs-set/overlays/nur.nix
Normal file
1
pkgs-set/overlays/nur.nix
Normal file
@ -0,0 +1 @@
|
|||||||
|
{inputs}: inputs.nur.overlay
|
@ -1,6 +1,10 @@
|
|||||||
|
pkgs: (
|
||||||
|
pkgs.lib.getAttrs
|
||||||
[
|
[
|
||||||
"discord-system-electron"
|
"discord-system-electron"
|
||||||
"fractal-next"
|
"fractal-next"
|
||||||
"gamescope"
|
"gamescope"
|
||||||
"gaudible"
|
"gaudible"
|
||||||
]
|
]
|
||||||
|
pkgs
|
||||||
|
)
|
||||||
|
12
pkgs-set/pkgs/generate-firefox-addons.nix
Normal file
12
pkgs-set/pkgs/generate-firefox-addons.nix
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
{
|
||||||
|
nur,
|
||||||
|
treefmt,
|
||||||
|
writers,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
writers.writeBashBin "generate-firefox-addons" ''
|
||||||
|
${nur.repos.rycee.firefox-addons-generator}/bin/nixpkgs-firefox-addons \
|
||||||
|
users/modules/firefox/extensions.json \
|
||||||
|
users/modules/firefox/extensions.nix
|
||||||
|
${treefmt}/bin/treefmt
|
||||||
|
''
|
71
users/modules/firefox/default.nix
Normal file
71
users/modules/firefox/default.nix
Normal file
@ -0,0 +1,71 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
config,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [".mozilla"];
|
||||||
|
programs.firefox = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.firefox-wayland.override {
|
||||||
|
extraPrefs = ''
|
||||||
|
lockPref("privacy.resistFingerprinting.letterboxing", false);
|
||||||
|
lockPref("browser.startup.homepage", "about:home");
|
||||||
|
lockPref("browser.newtabpage.enabled", true);
|
||||||
|
lockPref("browser.startup.page", 1);
|
||||||
|
lockPref("privacy.clearOnShutdown.downloads", false);
|
||||||
|
lockPref("privacy.clearOnShutdown.formdata", false);
|
||||||
|
lockPref("privacy.clearOnShutdown.history", false);
|
||||||
|
lockPref("privacy.clearOnShutdown.offlineApps", false);
|
||||||
|
lockPref("privacy.clearOnShutdown.sessions", false);
|
||||||
|
lockPref("services.sync.engine.passwords", false);
|
||||||
|
'';
|
||||||
|
extraPolicies = {
|
||||||
|
CaptivePortal = false;
|
||||||
|
DisableFirefoxStudies = true;
|
||||||
|
DisablePocket = true;
|
||||||
|
DisableTelemetry = true;
|
||||||
|
DisableFirefoxAccounts = true;
|
||||||
|
FirefoxHome = {
|
||||||
|
Pocket = false;
|
||||||
|
Snippets = false;
|
||||||
|
};
|
||||||
|
UserMessaging = {
|
||||||
|
ExtensionRecommendations = false;
|
||||||
|
SkipOnboarding = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
extensions = with pkgs.nur.repos.rycee.firefox-addons; let
|
||||||
|
myExtensions =
|
||||||
|
pkgs.callPackage ./extensions.nix {inherit buildFirefoxXpiAddon;};
|
||||||
|
in
|
||||||
|
[
|
||||||
|
ublock-origin
|
||||||
|
darkreader
|
||||||
|
bitwarden
|
||||||
|
refined-github
|
||||||
|
stylus
|
||||||
|
]
|
||||||
|
++ (with myExtensions; [
|
||||||
|
catppuccin-mocha-sky
|
||||||
|
]);
|
||||||
|
profiles = {
|
||||||
|
default = {
|
||||||
|
id = 0;
|
||||||
|
isDefault = false;
|
||||||
|
name = "defaulta";
|
||||||
|
};
|
||||||
|
personal = {
|
||||||
|
id = 1;
|
||||||
|
isDefault = true;
|
||||||
|
name = "personal";
|
||||||
|
extraConfig = builtins.readFile (
|
||||||
|
builtins.fetchurl {
|
||||||
|
url = "https://raw.githubusercontent.com/arkenfox/user.js/101.0/user.js";
|
||||||
|
sha256 = "sha256:1mb1l9dgb8mfl70lhwykgfphqnxxi1xw0h3hlgj8jyj6n1mn5v8f";
|
||||||
|
}
|
||||||
|
);
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
3
users/modules/firefox/extensions.json
Normal file
3
users/modules/firefox/extensions.json
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
[
|
||||||
|
{"slug":"catppuccin-mocha-sky"}
|
||||||
|
]
|
18
users/modules/firefox/extensions.nix
Normal file
18
users/modules/firefox/extensions.nix
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
buildFirefoxXpiAddon,
|
||||||
|
fetchurl,
|
||||||
|
lib,
|
||||||
|
stdenv,
|
||||||
|
}: {
|
||||||
|
"catppuccin-mocha-sky" = buildFirefoxXpiAddon {
|
||||||
|
pname = "catppuccin-mocha-sky";
|
||||||
|
version = "2.0";
|
||||||
|
addonId = "{12eeb304-58cd-4bcb-9676-99562b04f066}";
|
||||||
|
url = "https://addons.mozilla.org/firefox/downloads/file/3954372/catppuccin_dark_sky-2.0.xpi";
|
||||||
|
sha256 = "d9453ae265608d3a1b17c812d77422ab2aaf357365e527812268a407643efa25";
|
||||||
|
meta = with lib; {
|
||||||
|
description = "Firefox theme based on <a href=\"https://outgoing.prod.mozaws.net/v1/110954a3f2718cf03892676379416caed51099b639f643aaf12989b7e698f073/https%3A//github.com/catppuccin/catppuccin\" rel=\"nofollow\">https://github.com/catppuccin/catppuccin</a>";
|
||||||
|
platforms = platforms.all;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
28
users/modules/font/default.nix
Normal file
28
users/modules/font/default.nix
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
{
|
||||||
|
lib,
|
||||||
|
config,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
cfg = config.fonts.settings;
|
||||||
|
in
|
||||||
|
with lib; {
|
||||||
|
options.fonts.settings = {
|
||||||
|
enable = mkOption {
|
||||||
|
type = types.bool;
|
||||||
|
default = false;
|
||||||
|
};
|
||||||
|
name = mkOption {
|
||||||
|
type = types.str;
|
||||||
|
};
|
||||||
|
package = mkOption {
|
||||||
|
type = types.package;
|
||||||
|
};
|
||||||
|
size = mkOption {
|
||||||
|
type = types.ints.unsigned;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
home.packages = [cfg.package];
|
||||||
|
};
|
||||||
|
}
|
149
users/modules/hyprland/default.nix
Normal file
149
users/modules/hyprland/default.nix
Normal file
@ -0,0 +1,149 @@
|
|||||||
|
{pkgs, ...}: {
|
||||||
|
systemd.user.targets.hyprland-session = {
|
||||||
|
Unit = {
|
||||||
|
Description = "hyprland compositor session";
|
||||||
|
Documentation = ["man:systemd.special(7)"];
|
||||||
|
BindsTo = ["graphical-session.target"];
|
||||||
|
Wants = ["graphical-session-pre.target"];
|
||||||
|
After = ["graphical-session-pre.target"];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
xdg.enable = true;
|
||||||
|
xdg.configFile."hypr/hyprland.conf".text = let
|
||||||
|
rofi = "${pkgs.rofi-wayland}/bin/rofi";
|
||||||
|
launcher = "${rofi} -show drun";
|
||||||
|
term = "${pkgs.wezterm}/bin/wezterm";
|
||||||
|
|
||||||
|
swaybg = "${pkgs.swaybg}/bin/swaybg";
|
||||||
|
grim = "${pkgs.grim}/bin/grim";
|
||||||
|
light = "${pkgs.light}/bin/light";
|
||||||
|
playerctl = "${pkgs.playerctl}/bin/playerctl";
|
||||||
|
pulsemixer = "${pkgs.pulsemixer}/bin/pulsemixer";
|
||||||
|
slurp = "${pkgs.slurp}/bin/slurp";
|
||||||
|
wl-copy = "${pkgs.wl-clipboard}/bin/wl-copy";
|
||||||
|
notify-date = with pkgs;
|
||||||
|
writers.writeBash "notify-date" ''
|
||||||
|
${libnotify}/bin/notify-send " $(${coreutils}/bin/date +'%H:%M %d/%m/%Y')"
|
||||||
|
'';
|
||||||
|
in ''
|
||||||
|
# should be configured per-profile
|
||||||
|
monitor=HDMI-A-1,1920x1080@60,0x0,1
|
||||||
|
workspace=HDMI-A-1,1
|
||||||
|
exec-once=dbus-update-activation-environment --systemd WAYLAND_DISPLAY DISPLAY HYPRLAND_INSTANCE_SIGNATURE
|
||||||
|
exec-once=systemctl --user start graphical-session-pre.target
|
||||||
|
exec-once=systemctl --user start graphical-session.target
|
||||||
|
exec-once=${swaybg} -i ~/.config/wallpaper
|
||||||
|
input {
|
||||||
|
kb_layout=tr
|
||||||
|
kb_variant=
|
||||||
|
kb_model=
|
||||||
|
kb_options=
|
||||||
|
kb_rules=
|
||||||
|
follow_mouse=1
|
||||||
|
force_no_accel=1
|
||||||
|
touchpad {
|
||||||
|
natural_scroll=1
|
||||||
|
}
|
||||||
|
}
|
||||||
|
general {
|
||||||
|
sensitivity=1
|
||||||
|
main_mod=SUPER
|
||||||
|
gaps_in=5
|
||||||
|
gaps_out=5
|
||||||
|
border_size=0
|
||||||
|
damage_tracking=full
|
||||||
|
}
|
||||||
|
decoration {
|
||||||
|
rounding=16
|
||||||
|
blur=1
|
||||||
|
blur_size=3 # minimum 1
|
||||||
|
blur_passes=3 # minimum 1, more passes = more resource intensive.
|
||||||
|
# Your blur "amount" is blur_size * blur_passes, but high blur_size (over around 5-ish) will produce artifacts.
|
||||||
|
# if you want heavy blur, you need to up the blur_passes.
|
||||||
|
# the more passes, the more you can up the blur_size without noticing artifacts.
|
||||||
|
}
|
||||||
|
animations {
|
||||||
|
enabled=1
|
||||||
|
animation=windows,1,2,default
|
||||||
|
animation=borders,1,2,default
|
||||||
|
animation=fadein,1,2,default
|
||||||
|
animation=workspaces,1,2,slide
|
||||||
|
}
|
||||||
|
dwindle {
|
||||||
|
pseudotile=0 # enable pseudotiling on dwindle
|
||||||
|
}
|
||||||
|
# example window rules
|
||||||
|
# for windows named/classed as abc and xyz
|
||||||
|
#windowrule=move 69 420,abc
|
||||||
|
#windowrule=size 420 69,abc
|
||||||
|
#windowrule=tile,xyz
|
||||||
|
#windowrule=float,abc
|
||||||
|
#windowrule=pseudo,abc
|
||||||
|
#windowrule=monitor 0,xyz
|
||||||
|
bind=SUPER,RETURN,exec,${term}
|
||||||
|
bind=SUPER,D,exec,${launcher}
|
||||||
|
bind=SUPER,Q,killactive,
|
||||||
|
bind=SUPERSHIFT,E,exec,pkill Hyprland
|
||||||
|
bind=SUPER,F,fullscreen,
|
||||||
|
bind=SUPER,P,pseudo,
|
||||||
|
bind=SUPER,T,exec,${notify-date}
|
||||||
|
bind=SUPERSHIFT,T,togglefloating,
|
||||||
|
bind=,XF86AudioPlay,exec,${playerctl} play-pause
|
||||||
|
bind=,XF86AudioPrev,exec,${playerctl} previous
|
||||||
|
bind=,XF86AudioNext,exec,${playerctl} next
|
||||||
|
bind=,XF86AudioRaiseVolume,exec,${pulsemixer} --change-volume +6
|
||||||
|
bind=,XF86AudioLowerVolume,exec,${pulsemixer} --change-volume -6
|
||||||
|
bind=,XF86AudioMute,exec,${pulsemixer} --toggle-mute
|
||||||
|
bind=,XF86MonBrightnessUp,exec,${light} -A 5
|
||||||
|
bind=,XF86MonBrightnessDown,exec,${light} -U 5
|
||||||
|
# screenshot
|
||||||
|
# selection
|
||||||
|
$ssselection=${grim} -g "$(${slurp})" - | ${wl-copy} -t image/png
|
||||||
|
bind=,Print,exec,$ssselection
|
||||||
|
bind=SUPERSHIFT,R,exec,$ssselection
|
||||||
|
# monitor
|
||||||
|
$ssmonitor=${grim} -o "$(${slurp} -f %o -or)" - | ${wl-copy} -t image/png
|
||||||
|
bind=CTRL,Print,exec,$ssmonitor
|
||||||
|
bind=SUPERSHIFTCTRL,R,exec,$ssmonitor
|
||||||
|
# all-monitors
|
||||||
|
$ssall=${grim} - | ${wl-copy} -t image/png
|
||||||
|
bind=ALT,Print,exec,$ssall
|
||||||
|
bind=SUPERSHIFTALT,R,exec,$ssall
|
||||||
|
# move focus
|
||||||
|
bind=SUPER,left,movefocus,l
|
||||||
|
bind=SUPER,right,movefocus,r
|
||||||
|
bind=SUPER,up,movefocus,u
|
||||||
|
bind=SUPER,down,movefocus,d
|
||||||
|
# go to workspace
|
||||||
|
bind=SUPER,grave,togglespecialworkspace,eDP-1
|
||||||
|
bind=SUPER,1,workspace,1
|
||||||
|
bind=SUPER,2,workspace,2
|
||||||
|
bind=SUPER,3,workspace,3
|
||||||
|
bind=SUPER,4,workspace,4
|
||||||
|
bind=SUPER,5,workspace,5
|
||||||
|
bind=SUPER,6,workspace,6
|
||||||
|
bind=SUPER,7,workspace,7
|
||||||
|
bind=SUPER,8,workspace,8
|
||||||
|
bind=SUPER,9,workspace,9
|
||||||
|
bind=SUPER,0,workspace,10
|
||||||
|
# cycle workspaces
|
||||||
|
bind=SUPER,bracketleft,workspace,m-1
|
||||||
|
bind=SUPER,bracketright,workspace,m+1
|
||||||
|
# cycle monitors
|
||||||
|
bind=SUPERSHIFT,braceleft,focusmonitor,l
|
||||||
|
bind=SUPERSHIFT,braceright,focusmonitor,r
|
||||||
|
# move to workspace
|
||||||
|
bind=SUPERSHIFT,asciitilde,movetoworkspace,special
|
||||||
|
bind=SUPERSHIFT,exclam,movetoworkspace,1
|
||||||
|
bind=SUPERSHIFT,at,movetoworkspace,2
|
||||||
|
bind=SUPERSHIFT,numbersign,movetoworkspace,3
|
||||||
|
bind=SUPERSHIFT,dollar,movetoworkspace,4
|
||||||
|
bind=SUPERSHIFT,percent,movetoworkspace,5
|
||||||
|
bind=SUPERSHIFT,asciicircum,movetoworkspace,6
|
||||||
|
bind=SUPERSHIFT,ampersand,movetoworkspace,7
|
||||||
|
bind=SUPERSHIFT,asterisk,movetoworkspace,8
|
||||||
|
bind=SUPERSHIFT,parenleft,movetoworkspace,9
|
||||||
|
bind=SUPERSHIFT,parenright,movetoworkspace,10
|
||||||
|
'';
|
||||||
|
}
|
18
users/modules/mako/default.nix
Normal file
18
users/modules/mako/default.nix
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
config,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
programs.mako = {
|
||||||
|
enable = true;
|
||||||
|
anchor = "top-center";
|
||||||
|
font = "${config.fonts.settings.name} ${toString config.fonts.settings.size}";
|
||||||
|
borderRadius = 16;
|
||||||
|
extraConfig = builtins.readFile (
|
||||||
|
builtins.fetchurl {
|
||||||
|
url = "https://raw.githubusercontent.com/catppuccin/mako/d077d9832e8f22777a4812eadbfb658e793cbdfc/config";
|
||||||
|
sha256 = "sha256:1c8j16ljbnynb5kplxvhg99rw536hbxxz1rl8qgaixdf2bg2awp0";
|
||||||
|
}
|
||||||
|
);
|
||||||
|
};
|
||||||
|
}
|
119
users/modules/rofi/default.nix
Normal file
119
users/modules/rofi/default.nix
Normal file
@ -0,0 +1,119 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
config,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
home.packages = [pkgs.rofi-wayland];
|
||||||
|
xdg.enable = true;
|
||||||
|
xdg.dataFile = {
|
||||||
|
"rofi/themes/catppuccin.rasi".source = builtins.fetchurl {
|
||||||
|
url = "https://raw.githubusercontent.com/catppuccin/rofi/c7c242d6bfd4cabdc9a220cff71e3b0766811fbe/.local/share/rofi/themes/catppuccin.rasi";
|
||||||
|
sha256 = "sha256:17jssby0llsnabzfz3lp4wcc9vdzfz77i5wjcclfcyyvpswc53nx";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
xdg.configFile = {
|
||||||
|
"rofi/config.rasi".text = ''
|
||||||
|
configuration{
|
||||||
|
modi: "drun";
|
||||||
|
lines: 5;
|
||||||
|
font: "${config.fonts.settings.name} ${toString config.fonts.settings.size}";
|
||||||
|
show-icons: true;
|
||||||
|
terminal: "st";
|
||||||
|
drun-display-format: "{icon} {name}";
|
||||||
|
location: 0;
|
||||||
|
disable-history: false;
|
||||||
|
hide-scrollbar: true;
|
||||||
|
display-drun: " Apps ";
|
||||||
|
display-run: " Run ";
|
||||||
|
display-window: " Window";
|
||||||
|
display-Network: " Network";
|
||||||
|
sidebar-mode: true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@theme "catppuccin"
|
||||||
|
|
||||||
|
element-text, element-icon , mode-switcher {
|
||||||
|
background-color: inherit;
|
||||||
|
text-color: inherit;
|
||||||
|
}
|
||||||
|
|
||||||
|
window {
|
||||||
|
height: 360px;
|
||||||
|
border: 3px;
|
||||||
|
border-color: @border-col;
|
||||||
|
background-color: @bg-col;
|
||||||
|
}
|
||||||
|
|
||||||
|
mainbox {
|
||||||
|
background-color: @bg-col;
|
||||||
|
}
|
||||||
|
|
||||||
|
inputbar {
|
||||||
|
children: [prompt,entry];
|
||||||
|
background-color: @bg-col;
|
||||||
|
border-radius: 5px;
|
||||||
|
padding: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
prompt {
|
||||||
|
background-color: @blue;
|
||||||
|
padding: 6px;
|
||||||
|
text-color: @bg-col;
|
||||||
|
border-radius: 3px;
|
||||||
|
margin: 20px 0px 0px 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
textbox-prompt-colon {
|
||||||
|
expand: false;
|
||||||
|
str: ":";
|
||||||
|
}
|
||||||
|
|
||||||
|
entry {
|
||||||
|
padding: 6px;
|
||||||
|
margin: 20px 0px 0px 10px;
|
||||||
|
text-color: @fg-col;
|
||||||
|
background-color: @bg-col;
|
||||||
|
}
|
||||||
|
|
||||||
|
listview {
|
||||||
|
border: 0px 0px 0px;
|
||||||
|
padding: 6px 0px 0px;
|
||||||
|
margin: 10px 0px 0px 20px;
|
||||||
|
columns: 2;
|
||||||
|
background-color: @bg-col;
|
||||||
|
}
|
||||||
|
|
||||||
|
element {
|
||||||
|
padding: 5px;
|
||||||
|
background-color: @bg-col;
|
||||||
|
text-color: @fg-col ;
|
||||||
|
}
|
||||||
|
|
||||||
|
element-icon {
|
||||||
|
size: 25px;
|
||||||
|
}
|
||||||
|
|
||||||
|
element selected {
|
||||||
|
background-color: @selected-col ;
|
||||||
|
text-color: @fg-col2 ;
|
||||||
|
}
|
||||||
|
|
||||||
|
mode-switcher {
|
||||||
|
spacing: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
button {
|
||||||
|
padding: 10px;
|
||||||
|
background-color: @bg-col-light;
|
||||||
|
text-color: @grey;
|
||||||
|
vertical-align: 0.5;
|
||||||
|
horizontal-align: 0.5;
|
||||||
|
}
|
||||||
|
|
||||||
|
button selected {
|
||||||
|
background-color: @bg-col;
|
||||||
|
text-color: @blue;
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
}
|
32
users/modules/wezterm/default.nix
Normal file
32
users/modules/wezterm/default.nix
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
config,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
home.packages = [pkgs.wezterm];
|
||||||
|
xdg.enable = true;
|
||||||
|
xdg.configFile = {
|
||||||
|
"wezterm/wezterm.lua".text = ''
|
||||||
|
local wezterm = require 'wezterm';
|
||||||
|
local catppuccin = require("colors/catppuccin").setup {
|
||||||
|
-- whether or not to sync with the system's theme
|
||||||
|
sync = false,
|
||||||
|
-- the default/fallback flavour, when syncing is disabled
|
||||||
|
flavour = "mocha"
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
font = wezterm.font("${config.fonts.settings.name}"),
|
||||||
|
font_size = ${builtins.toJSON config.fonts.settings.size},
|
||||||
|
default_cursor_style = "BlinkingBar",
|
||||||
|
enable_wayland = true,
|
||||||
|
enable_tab_bar = false,
|
||||||
|
colors = catppuccin
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
"wezterm/colors/catppuccin.lua".source = builtins.fetchurl {
|
||||||
|
url = "https://raw.githubusercontent.com/catppuccin/wezterm/65078e846c8751e9b4837a575deb0745f0c0512f/catppuccin.lua";
|
||||||
|
sha256 = "sha256:0cm8kjjga9k1fzgb7nqjwd1jdjqjrkkqaxcavfxdkl3mw7qiy1ib";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
14
users/modules/zoxide/default.nix
Normal file
14
users/modules/zoxide/default.nix
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
home.packages = [pkgs.zoxide];
|
||||||
|
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories =
|
||||||
|
lib.singleton
|
||||||
|
".local/share/zoxide";
|
||||||
|
programs.zsh.initExtra = ''
|
||||||
|
eval "$(zoxide init zsh)"
|
||||||
|
'';
|
||||||
|
}
|
@ -1,24 +0,0 @@
|
|||||||
{font, ...}: ''
|
|
||||||
local wezterm = require 'wezterm';
|
|
||||||
local catppuccin = require("colors/catppuccin").setup {
|
|
||||||
-- whether or not to sync with the system's theme
|
|
||||||
sync = true,
|
|
||||||
-- the flavours to switch between when syncing
|
|
||||||
-- available flavours: "latte" | "frappe" | "macchiato" | "mocha"
|
|
||||||
sync_flavours = {
|
|
||||||
light = "latte",
|
|
||||||
dark = "mocha"
|
|
||||||
},
|
|
||||||
-- the default/fallback flavour, when syncing is disabled
|
|
||||||
flavour = "mocha"
|
|
||||||
}
|
|
||||||
|
|
||||||
return {
|
|
||||||
font = wezterm.font("${font.name}"),
|
|
||||||
font_size = ${builtins.toJSON font.size},
|
|
||||||
default_cursor_style = "BlinkingBar",
|
|
||||||
enable_wayland = true,
|
|
||||||
enable_tab_bar = false,
|
|
||||||
colors = catppuccin
|
|
||||||
}
|
|
||||||
''
|
|
@ -2,15 +2,19 @@
|
|||||||
pkgs,
|
pkgs,
|
||||||
lib,
|
lib,
|
||||||
tlib,
|
tlib,
|
||||||
|
config,
|
||||||
|
inputs,
|
||||||
...
|
...
|
||||||
} @ globalAttrs: let
|
} @ globalAttrs: let
|
||||||
inherit (lib) mapAttrs' nameValuePair;
|
inherit (lib) mapAttrs' nameValuePair;
|
||||||
inherit (builtins) readDir fetchGit;
|
inherit (builtins) readDir fetchGit;
|
||||||
|
l = lib // builtins;
|
||||||
|
|
||||||
pkgBin = tlib.pkgBin pkgs;
|
pkgBin = tlib.pkgBin pkgs;
|
||||||
nixosConfig = globalAttrs.config;
|
nixosConfig = globalAttrs.config;
|
||||||
useWayland = false;
|
|
||||||
in {
|
in {
|
||||||
|
imports = [inputs.hyprland.nixosModules.default];
|
||||||
|
|
||||||
users.users.patriot = {
|
users.users.patriot = {
|
||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
createHome = true;
|
createHome = true;
|
||||||
@ -24,73 +28,33 @@ in {
|
|||||||
hashedPassword = "$6$spzqhAyJfhHy$iHgLBlhjGn1l8PnbjJdWTn1GPvcjMqYNKUzdCe/7IrX6sHNgETSr/Nfpdmq9FCXLhrAfwHOd/q/8SvfeIeNX4/";
|
hashedPassword = "$6$spzqhAyJfhHy$iHgLBlhjGn1l8PnbjJdWTn1GPvcjMqYNKUzdCe/7IrX6sHNgETSr/Nfpdmq9FCXLhrAfwHOd/q/8SvfeIeNX4/";
|
||||||
};
|
};
|
||||||
environment = {
|
environment = {
|
||||||
systemPackages = lib.optional useWayland pkgs.qt5.qtwayland;
|
systemPackages = [pkgs.qt5.qtwayland];
|
||||||
shells = with pkgs; [bashInteractive zsh];
|
shells = with pkgs; [bashInteractive zsh];
|
||||||
};
|
};
|
||||||
xdg.portal = {
|
xdg.portal = {
|
||||||
enable = true;
|
enable = true;
|
||||||
wlr.enable = useWayland;
|
wlr.enable = true;
|
||||||
gtkUsePortal = false;
|
gtkUsePortal = true;
|
||||||
extraPortals = lib.optional useWayland pkgs.xdg-desktop-portal-wlr;
|
extraPortals = with pkgs; [xdg-desktop-portal-gtk xdg-desktop-portal-wlr];
|
||||||
};
|
};
|
||||||
programs = {
|
programs = {
|
||||||
|
# this is needed for impermanence
|
||||||
fuse.userAllowOther = true;
|
fuse.userAllowOther = true;
|
||||||
adb.enable = true;
|
adb.enable = true;
|
||||||
steam.enable = true;
|
steam.enable = true;
|
||||||
kdeconnect = {
|
# gnome stuffs
|
||||||
enable = true;
|
|
||||||
package = pkgs.gnomeExtensions.gsconnect;
|
|
||||||
};
|
|
||||||
gnome-disks.enable = false;
|
|
||||||
file-roller.enable = false;
|
|
||||||
seahorse.enable = true;
|
seahorse.enable = true;
|
||||||
|
hyprland.enable = true;
|
||||||
|
hyprland.extraPackages = [];
|
||||||
};
|
};
|
||||||
security = {
|
# gnome keyring better fr fr
|
||||||
pam.services.patriot = {
|
security.pam.services.patriot = {
|
||||||
enableGnomeKeyring = true;
|
enableGnomeKeyring = true;
|
||||||
enableKwallet = false;
|
enableKwallet = false;
|
||||||
};
|
};
|
||||||
};
|
|
||||||
services = {
|
|
||||||
gnome = {
|
|
||||||
gnome-keyring.enable = true;
|
|
||||||
core-shell.enable = true;
|
|
||||||
core-os-services.enable = true;
|
|
||||||
chrome-gnome-shell.enable = true;
|
|
||||||
at-spi2-core.enable = true;
|
|
||||||
gnome-online-accounts.enable = false;
|
|
||||||
gnome-online-miners.enable = lib.mkForce false;
|
|
||||||
gnome-remote-desktop.enable = false;
|
|
||||||
core-utilities.enable = false;
|
|
||||||
tracker-miners.enable = false;
|
|
||||||
tracker.enable = false;
|
|
||||||
gnome-settings-daemon.enable = lib.mkForce false;
|
|
||||||
sushi.enable = false;
|
|
||||||
};
|
|
||||||
xserver = {
|
|
||||||
enable = true;
|
|
||||||
desktopManager = {
|
|
||||||
gnome.enable = true;
|
|
||||||
xterm.enable = false;
|
|
||||||
};
|
|
||||||
displayManager = {
|
|
||||||
autoLogin = {
|
|
||||||
enable = true;
|
|
||||||
user = "patriot";
|
|
||||||
};
|
|
||||||
gdm = {
|
|
||||||
enable = true;
|
|
||||||
wayland = useWayland;
|
|
||||||
};
|
|
||||||
startx.enable = false;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
systemd = {
|
systemd = {
|
||||||
targets.network-online.enable = false;
|
targets.network-online.enable = false;
|
||||||
services = {
|
services = {
|
||||||
"getty@tty1".enable = false;
|
|
||||||
"autovt@tty1".enable = false;
|
|
||||||
systemd-networkd-wait-online.enable = false;
|
systemd-networkd-wait-online.enable = false;
|
||||||
NetworkManager-wait-online.enable = false;
|
NetworkManager-wait-online.enable = false;
|
||||||
};
|
};
|
||||||
@ -104,41 +68,29 @@ in {
|
|||||||
personal = import ../../personal.nix;
|
personal = import ../../personal.nix;
|
||||||
name = personal.name;
|
name = personal.name;
|
||||||
email = personal.emails.primary;
|
email = personal.emails.primary;
|
||||||
font = {
|
|
||||||
name = "Comic Mono";
|
|
||||||
size = 13;
|
|
||||||
package = let
|
|
||||||
ttf = pkgs.fetchurl {
|
|
||||||
url = "https://dtinth.github.io/comic-mono-font/ComicMono.ttf";
|
|
||||||
sha256 = "sha256-O8FCXpIqFqvw7HZ+/+TQJoQ5tMDc6YQy4H0V9drVcZY=";
|
|
||||||
};
|
|
||||||
in
|
|
||||||
pkgs.runCommand "comic-mono" {} ''
|
|
||||||
mkdir -p $out/share/fonts/truetype
|
|
||||||
ln -s ${ttf} $out/share/fonts/truetype
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
in {
|
in {
|
||||||
imports = [
|
imports = [
|
||||||
../modules/direnv
|
../modules/direnv
|
||||||
../modules/git
|
../modules/git
|
||||||
../modules/starship
|
../modules/starship
|
||||||
../modules/helix
|
../modules/helix
|
||||||
|
../modules/zoxide
|
||||||
|
../modules/wezterm
|
||||||
|
../modules/hyprland
|
||||||
|
../modules/rofi
|
||||||
|
../modules/mako
|
||||||
|
../modules/font
|
||||||
|
../modules/firefox
|
||||||
|
../../modules/persist
|
||||||
# ../modules/smos
|
# ../modules/smos
|
||||||
inputs.nixos-persistence.nixosModules.home-manager.impermanence
|
inputs.nixos-persistence.nixosModules.home-manager.impermanence
|
||||||
];
|
];
|
||||||
|
|
||||||
gtk = {
|
system.persistDir = nixosConfig.system.persistDir;
|
||||||
enable = true;
|
|
||||||
theme = {
|
|
||||||
name = "Catppuccin";
|
|
||||||
package = pkgs.catppuccin-gtk;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home.persistence."/persist/home/patriot" = let
|
home.persistence."${config.system.persistDir}${config.home.homeDirectory}" = let
|
||||||
mkPaths = prefix: paths:
|
mkPaths = prefix: paths:
|
||||||
builtins.map (n: "${prefix}/${n}") paths;
|
builtins.map (n: "${prefix}/${n}") (l.flatten paths);
|
||||||
in {
|
in {
|
||||||
directories =
|
directories =
|
||||||
[
|
[
|
||||||
@ -157,41 +109,50 @@ in {
|
|||||||
".cache"
|
".cache"
|
||||||
]
|
]
|
||||||
++ mkPaths ".local/share" [
|
++ mkPaths ".local/share" [
|
||||||
"zoxide"
|
|
||||||
"direnv"
|
"direnv"
|
||||||
"zsh"
|
"zsh"
|
||||||
"Steam"
|
"Steam"
|
||||||
"backgrounds"
|
|
||||||
"keyrings"
|
"keyrings"
|
||||||
"lutris"
|
"lutris"
|
||||||
"PolyMC"
|
"PolyMC"
|
||||||
]
|
]
|
||||||
++ mkPaths ".config" [
|
++ mkPaths ".config" [
|
||||||
"dconf"
|
|
||||||
"chromium"
|
|
||||||
"gsconnect"
|
|
||||||
"lutris"
|
"lutris"
|
||||||
];
|
];
|
||||||
files = [
|
files = l.flatten [
|
||||||
".config/gnome-initial-setup-done"
|
".config/wallpaper"
|
||||||
(lib.removePrefix "~/" config.programs.ssh.userKnownHostsFile)
|
(lib.removePrefix "~/" config.programs.ssh.userKnownHostsFile)
|
||||||
];
|
];
|
||||||
allowOther = true;
|
allowOther = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
fonts.fontconfig.enable = lib.mkForce true;
|
fonts.fontconfig.enable = lib.mkForce true;
|
||||||
|
fonts.settings = {
|
||||||
|
enable = true;
|
||||||
|
name = "Comic Mono";
|
||||||
|
size = 13;
|
||||||
|
package = let
|
||||||
|
ttf = pkgs.fetchurl {
|
||||||
|
url = "https://dtinth.github.io/comic-mono-font/ComicMono.ttf";
|
||||||
|
sha256 = "sha256-O8FCXpIqFqvw7HZ+/+TQJoQ5tMDc6YQy4H0V9drVcZY=";
|
||||||
|
};
|
||||||
|
in
|
||||||
|
pkgs.runCommandNoCC "comic-mono" {} ''
|
||||||
|
mkdir -p $out/share/fonts/truetype
|
||||||
|
ln -s ${ttf} $out/share/fonts/truetype
|
||||||
|
'';
|
||||||
|
};
|
||||||
home = {
|
home = {
|
||||||
stateVersion = nixosConfig.system.stateVersion;
|
stateVersion = nixosConfig.system.stateVersion;
|
||||||
homeDirectory = nixosConfig.users.users.patriot.home;
|
homeDirectory = nixosConfig.users.users.patriot.home;
|
||||||
packages = with pkgs; [
|
packages = with pkgs;
|
||||||
|
l.flatten [
|
||||||
# Font stuff
|
# Font stuff
|
||||||
font.package
|
|
||||||
noto-fonts-cjk
|
noto-fonts-cjk
|
||||||
font-awesome
|
font-awesome
|
||||||
dejavu_fonts
|
dejavu_fonts
|
||||||
# Programs
|
# Programs
|
||||||
bitwarden
|
bitwarden
|
||||||
wezterm
|
|
||||||
cargo-outdated
|
cargo-outdated
|
||||||
cargo-release
|
cargo-release
|
||||||
cargo-udeps
|
cargo-udeps
|
||||||
@ -210,8 +171,6 @@ in {
|
|||||||
# polymc
|
# polymc
|
||||||
cloudflared
|
cloudflared
|
||||||
lutris
|
lutris
|
||||||
gnome.gnome-themes-extra
|
|
||||||
gnome.gnome-tweaks
|
|
||||||
];
|
];
|
||||||
shellAliases =
|
shellAliases =
|
||||||
nixosConfig.environment.shellAliases
|
nixosConfig.environment.shellAliases
|
||||||
@ -222,40 +181,13 @@ in {
|
|||||||
};
|
};
|
||||||
sessionVariables =
|
sessionVariables =
|
||||||
nixosConfig.environment.sessionVariables
|
nixosConfig.environment.sessionVariables
|
||||||
// {
|
// l.optionalAttrs config.programs.fzf.enable {
|
||||||
FZF_DEFAULT_OPTS = "--color=bg+:#302D41,bg:#1E1E2E,spinner:#F8BD96,hl:#F28FAD --color=fg:#D9E0EE,header:#F28FAD,info:#DDB6F2,pointer:#F8BD96 --color=marker:#F8BD96,fg+:#F2CDCD,prompt:#DDB6F2,hl+:#F28FAD";
|
FZF_DEFAULT_OPTS = "--color=bg+:#302D41,bg:#1E1E2E,spinner:#F8BD96,hl:#F28FAD --color=fg:#D9E0EE,header:#F28FAD,info:#DDB6F2,pointer:#F8BD96 --color=marker:#F8BD96,fg+:#F2CDCD,prompt:#DDB6F2,hl+:#F28FAD";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
programs = {
|
programs = {
|
||||||
command-not-found.enable =
|
command-not-found.enable =
|
||||||
nixosConfig.programs.command-not-found.enable;
|
nixosConfig.programs.command-not-found.enable;
|
||||||
chromium = {
|
|
||||||
enable = true;
|
|
||||||
package =
|
|
||||||
if useWayland
|
|
||||||
then pkgs.chromium-wayland
|
|
||||||
else pkgs.chromium;
|
|
||||||
extensions = [
|
|
||||||
# https everywhere
|
|
||||||
"gcbommkclmclpchllfjekcdonpmejbdp"
|
|
||||||
# ublock
|
|
||||||
"cjpalhdlnbpafiamejdnhcphjbkeiagm"
|
|
||||||
# bitwarden
|
|
||||||
"nngceckbapebfimnlniiiahkandclblb"
|
|
||||||
# decentraleyes
|
|
||||||
"ldpochfccmkkmhdbclfhpagapcfdljkj"
|
|
||||||
# dark theme
|
|
||||||
"annfbnbieaamhaimclajlajpijgkdblo"
|
|
||||||
# dark reader
|
|
||||||
"eimadpbcbfnmbkopoojfekhnkhdbieeh"
|
|
||||||
# github refined
|
|
||||||
"hlepfoohegkhhmjieoechaddaejaokhf"
|
|
||||||
# privacy redirect
|
|
||||||
"pmcmeagblkinmogikoikkdjiligflglb"
|
|
||||||
# pronoundb
|
|
||||||
"nblkbiljcjfemkfjnhoobnojjgjdmknf"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
git = {
|
git = {
|
||||||
signing = {
|
signing = {
|
||||||
key = "E1C119F91F4CAE53E8445CAFBB57FCE7E35984F6";
|
key = "E1C119F91F4CAE53E8445CAFBB57FCE7E35984F6";
|
||||||
@ -285,30 +217,21 @@ in {
|
|||||||
enableVteIntegration = true;
|
enableVteIntegration = true;
|
||||||
enableAutosuggestions = true;
|
enableAutosuggestions = true;
|
||||||
enableCompletion = true;
|
enableCompletion = true;
|
||||||
plugins = let
|
plugins = [
|
||||||
fast-syntax-highlighting = let
|
|
||||||
name = "fast-syntax-highlighting";
|
|
||||||
in {
|
|
||||||
inherit name;
|
|
||||||
src = pkgs."zsh-${name}".out;
|
|
||||||
};
|
|
||||||
per-directory-history = {
|
|
||||||
name = "per-directory-history";
|
|
||||||
src =
|
|
||||||
pkgs.fetchFromGitHub
|
|
||||||
{
|
{
|
||||||
|
name = "per-directory-history";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
owner = "jimhester";
|
owner = "jimhester";
|
||||||
repo = "per-directory-history";
|
repo = "per-directory-history";
|
||||||
rev = "d2e291dd6434e340d9be0e15e1f5b94f32771c06";
|
rev = "d2e291dd6434e340d9be0e15e1f5b94f32771c06";
|
||||||
hash = "sha256-VHRgrVCqzILqOes8VXGjSgLek38BFs9eijmp0JHtD5Q=";
|
hash = "sha256-VHRgrVCqzILqOes8VXGjSgLek38BFs9eijmp0JHtD5Q=";
|
||||||
};
|
};
|
||||||
};
|
}
|
||||||
in [fast-syntax-highlighting per-directory-history];
|
];
|
||||||
# xdg compliant
|
# xdg compliant
|
||||||
dotDir = ".config/zsh";
|
dotDir = ".config/zsh";
|
||||||
history.path = "${config.home.homeDirectory}/.local/share/zsh/history";
|
history.path = "${config.home.homeDirectory}/.local/share/zsh/history";
|
||||||
initExtra = ''
|
initExtra = ''
|
||||||
export TERM=alacritty
|
|
||||||
export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)
|
export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)
|
||||||
|
|
||||||
function tomp4 () {
|
function tomp4 () {
|
||||||
@ -319,11 +242,16 @@ in {
|
|||||||
${pkgBin "ffmpeg"} -i $1 "$1.png"
|
${pkgBin "ffmpeg"} -i $1 "$1.png"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# fix some key stuff
|
||||||
bindkey "$terminfo[kRIT5]" forward-word
|
bindkey "$terminfo[kRIT5]" forward-word
|
||||||
bindkey "$terminfo[kLFT5]" backward-word
|
bindkey "$terminfo[kLFT5]" backward-word
|
||||||
|
# makes completions pog
|
||||||
zstyle ':completion:*' menu select
|
zstyle ':completion:*' menu select
|
||||||
|
'';
|
||||||
eval "$(zoxide init zsh)"
|
loginExtra = ''
|
||||||
|
if [[ "$(tty)" == "/dev/tty1" ]]; then
|
||||||
|
exec Hyprland
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
fzf.enable = true;
|
fzf.enable = true;
|
||||||
@ -340,17 +268,7 @@ in {
|
|||||||
defaultCacheTtlSsh = defaultCacheTtl;
|
defaultCacheTtlSsh = defaultCacheTtl;
|
||||||
maxCacheTtlSsh = maxCacheTtl;
|
maxCacheTtlSsh = maxCacheTtl;
|
||||||
grabKeyboardAndMouse = false;
|
grabKeyboardAndMouse = false;
|
||||||
pinentryFlavor = "gnome3";
|
pinentryFlavor = "gtk2";
|
||||||
};
|
|
||||||
};
|
|
||||||
xdg = {
|
|
||||||
enable = true;
|
|
||||||
configFile = {
|
|
||||||
"wezterm/wezterm.lua".text = import ./config/wezterm/cfg.nix {inherit font;};
|
|
||||||
"wezterm/colors/catppuccin.lua".source = builtins.fetchurl {
|
|
||||||
url = "https://raw.githubusercontent.com/catppuccin/wezterm/65078e846c8751e9b4837a575deb0745f0c0512f/catppuccin.lua";
|
|
||||||
sha256 = "sha256:0cm8kjjga9k1fzgb7nqjwd1jdjqjrkkqaxcavfxdkl3mw7qiy1ib";
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user