nix machine / user configurations

style: format everything tm

ptr.pet 2889fc6e 3ad96ca6

verified
Changed files
+1366 -964
hosts
lib
locale
modules
pkgs-set
secrets
shells
users
firewatch
modules
arrpc
chromium
code
discord
discordrp-mpris
dunst
firefox
fluxbox
foot
fzf
git
godot
helix
hyprland
lollypop
mako
musikcube
musikcubed
newsflash
obsidian
premid
psd
ripcord
rofi
rofi-nm
s3s
settings
smos
spotify
ssh
starship
sway
swaylock
urxvt
vesktop
wayland
wezterm
wlsunset
wtf
zoxide
zsh
patriot
root
+46 -49
flake.nix
···
# catppuccin-discord.flake = false;
};
-
outputs = inputs: let
-
lib = inputs.nixpkgs.lib.extend (_: _: builtins);
-
tlib = (import ./lib lib).extend (_: prev: rec {
-
makePkgs = system:
-
import ./pkgs-set {
-
inherit system lib inputs;
-
tlib = prev;
-
};
-
genPkgs = f: prev.genSystems (system: f (makePkgs system));
-
});
+
outputs =
+
inputs:
+
let
+
lib = inputs.nixpkgs.lib.extend (_: _: builtins);
+
tlib = (import ./lib lib).extend (
+
_: prev: rec {
+
makePkgs =
+
system:
+
import ./pkgs-set {
+
inherit system lib inputs;
+
tlib = prev;
+
};
+
genPkgs = f: prev.genSystems (system: f (makePkgs system));
+
}
+
);
-
allPkgs = tlib.genPkgs (x: x);
+
allPkgs = tlib.genPkgs (x: x);
-
miscApps =
-
lib.mapAttrs
-
(
-
_: cmds:
-
lib.mapAttrs
-
(_: cmd: {
-
type = "app";
-
program = cmd;
-
})
-
cmds
-
)
-
(
+
miscApps =
lib.mapAttrs
-
(
-
_: pkgs: {
-
generate-firefox-addons =
-
toString
-
"${pkgs.generate-firefox-addons}/bin/generate-firefox-addons";
-
dns = toString "${pkgs.dnsmngmt}/bin/dns";
-
nh = toString "${inputs.nh.packages.${pkgs.system}.default}/bin/nh";
-
}
-
)
-
allPkgs
-
);
-
in {
-
lib = tlib;
-
nixosConfigurations = import ./hosts {inherit lib tlib inputs;};
+
(
+
_: cmds:
+
lib.mapAttrs (_: cmd: {
+
type = "app";
+
program = cmd;
+
}) cmds
+
)
+
(
+
lib.mapAttrs (_: pkgs: {
+
generate-firefox-addons = toString "${pkgs.generate-firefox-addons}/bin/generate-firefox-addons";
+
dns = toString "${pkgs.dnsmngmt}/bin/dns";
+
nh = toString "${inputs.nh.packages.${pkgs.system}.default}/bin/nh";
+
}) allPkgs
+
);
+
in
+
{
+
lib = tlib;
+
nixosConfigurations = import ./hosts { inherit lib tlib inputs; };
-
packages = lib.mapAttrs (_: pkgs: pkgs._exported) allPkgs;
-
legacyPackages = allPkgs;
-
apps = miscApps
-
// (inputs.nixinate.nixinate.x86_64-linux inputs.self);
+
packages = lib.mapAttrs (_: pkgs: pkgs._exported) allPkgs;
+
legacyPackages = allPkgs;
+
apps = miscApps // (inputs.nixinate.nixinate.x86_64-linux inputs.self);
-
# topology = lib.mapAttrs (_: pkgs:
-
# import inputs.nixtopo {
-
# inherit pkgs;
-
# modules = [{nixosConfigurations = {inherit (inputs.self.nixosConfigurations) wolumonde;};}];
-
# })
-
# allPkgs;
+
# topology = lib.mapAttrs (_: pkgs:
+
# import inputs.nixtopo {
+
# inherit pkgs;
+
# modules = [{nixosConfigurations = {inherit (inputs.self.nixosConfigurations) wolumonde;};}];
+
# })
+
# allPkgs;
-
devShells = import ./shells {inherit lib tlib inputs;};
-
};
+
devShells = import ./shells { inherit lib tlib inputs; };
+
};
}
+14 -13
hosts/default.nix
···
lib,
tlib,
...
-
}: let
+
}:
+
let
baseModules = [
../modules
../locale
inputs.home.nixosModules.default
];
-
mkSystem = name: system: let
-
pkgs = tlib.makePkgs system;
-
in
+
mkSystem =
+
name: system:
+
let
+
pkgs = tlib.makePkgs system;
+
in
lib.nixosSystem {
inherit system;
-
modules =
-
baseModules
-
++ [
-
{networking.hostName = name;}
-
{nixpkgs.pkgs = pkgs;}
-
(import (./. + "/${name}/default.nix"))
-
];
-
specialArgs = {inherit inputs tlib;};
+
modules = baseModules ++ [
+
{ networking.hostName = name; }
+
{ nixpkgs.pkgs = pkgs; }
+
(import (./. + "/${name}/default.nix"))
+
];
+
specialArgs = { inherit inputs tlib; };
};
systems = {
···
wsl = "x86_64-linux";
};
in
-
lib.mapAttrs mkSystem systems
+
lib.mapAttrs mkSystem systems
+53 -33
hosts/lungmen/default.nix
···
pkgs,
inputs,
...
-
}: let
+
}:
+
let
btrfsPartPath = "/dev/disk/by-label/NIXOS";
-
btrfsOptions = ["compress-force=zstd" "noatime"];
-
in {
-
imports = with inputs;
-
with nixos-hardware.nixosModules; [
-
nixpkgs.nixosModules.notDetected
-
nixos-persistence.nixosModule
-
common-pc-ssd
-
common-pc
-
common-gpu-amd
-
common-cpu-amd
-
../../modules/persist
-
../../modules/network
-
#../../modules/develop/nixbuild
-
../../users/root
-
../../users/patriot
+
btrfsOptions = [
+
"compress-force=zstd"
+
"noatime"
];
+
in
+
{
+
imports =
+
with inputs;
+
with nixos-hardware.nixosModules;
+
[
+
nixpkgs.nixosModules.notDetected
+
nixos-persistence.nixosModule
+
common-pc-ssd
+
common-pc
+
common-gpu-amd
+
common-cpu-amd
+
../../modules/persist
+
../../modules/network
+
#../../modules/develop/nixbuild
+
../../users/root
+
../../users/patriot
+
];
system.persistDir = "/persist";
···
systemd-boot.configurationLimit = 10;
};
kernelPackages = pkgs.linuxPackages_latest;
-
supportedFilesystems = ["btrfs"];
+
supportedFilesystems = [ "btrfs" ];
initrd = {
-
availableKernelModules = ["xhci_pci" "ahci" "usb_storage" "usbhid" "sd_mod"];
-
kernelModules = ["amdgpu"];
+
availableKernelModules = [
+
"xhci_pci"
+
"ahci"
+
"usb_storage"
+
"usbhid"
+
"sd_mod"
+
];
+
kernelModules = [ "amdgpu" ];
};
-
kernelModules = ["kvm-amd"];
-
extraModulePackages = [];
-
kernel.sysctl = {"fs.inotify.max_user_watches" = 524288;};
+
kernelModules = [ "kvm-amd" ];
+
extraModulePackages = [ ];
+
kernel.sysctl = {
+
"fs.inotify.max_user_watches" = 524288;
+
};
};
fileSystems."/" = {
device = "none";
fsType = "tmpfs";
-
options = ["defaults" "size=2G" "mode=755"];
+
options = [
+
"defaults"
+
"size=2G"
+
"mode=755"
+
];
};
fileSystems."/nix" = {
device = btrfsPartPath;
fsType = "btrfs";
-
options = ["subvol=nix"] ++ btrfsOptions;
+
options = [ "subvol=nix" ] ++ btrfsOptions;
};
fileSystems."${config.system.persistDir}" = {
device = btrfsPartPath;
fsType = "btrfs";
-
options = ["subvol=persist"] ++ btrfsOptions;
+
options = [ "subvol=persist" ] ++ btrfsOptions;
neededForBoot = true;
};
fileSystems."/boot" = {
···
fsType = "vfat";
};
-
swapDevices = [];
+
swapDevices = [ ];
zramSwap = {
enable = true;
algorithm = "zstd";
···
vulkan-loader
amdvlk
];
-
extraPackages32 = with pkgs.pkgsi686Linux;
+
extraPackages32 =
+
with pkgs.pkgsi686Linux;
[
libvdpau-va-gl
vaapiVdpau
···
fonts = {
enableDefaultFonts = true;
fontconfig.enable = true;
-
fonts = [pkgs.dejavu_fonts];
+
fonts = [ pkgs.dejavu_fonts ];
};
environment = {
-
systemPackages = [pkgs.ntfs3g];
-
pathsToLink = ["/share/zsh"];
+
systemPackages = [ pkgs.ntfs3g ];
+
pathsToLink = [ "/share/zsh" ];
persistence."${config.system.persistDir}" = {
-
directories = ["/etc/nixos"];
-
files = ["/etc/machine-id"];
+
directories = [ "/etc/nixos" ];
+
files = [ "/etc/machine-id" ];
};
};
···
autoMount = true;
};
flatpak.enable = false;
-
xserver.videoDrivers = ["amdgpu"];
+
xserver.videoDrivers = [ "amdgpu" ];
};
system.stateVersion = "22.05";
+37 -14
hosts/tkaronto/default.nix
···
pkgs,
inputs,
...
-
}: {
-
imports = with inputs;
-
with nixos-hardware.nixosModules;
+
}:
+
{
+
imports =
+
with inputs;
+
with nixos-hardware.nixosModules;
[
# vfio.nixosModules.kvmfr
# vfio.nixosModules.virtualisation
···
support32Bit = true;
};
-
services.xserver.videoDrivers = ["nvidia" "amdgpu"];
+
services.xserver.videoDrivers = [
+
"nvidia"
+
"amdgpu"
+
];
hardware = {
nvidia = {
package = config.boot.kernelPackages.nvidiaPackages.production;
···
fonts = {
enableDefaultPackages = true;
fontconfig.enable = true;
-
packages = [pkgs.dejavu_fonts];
+
packages = [ pkgs.dejavu_fonts ];
};
environment = {
sessionVariables.FLAKE = "/etc/nixos";
-
pathsToLink = ["/share/zsh"];
+
pathsToLink = [ "/share/zsh" ];
persistence."${config.system.persistDir}" = {
directories = lib.flatten [
"/etc/nixos"
-
(
-
lib.optional
-
config.virtualisation.docker.enable
-
["/var/lib/docker" "/var/lib/containers"]
-
)
+
(lib.optional config.virtualisation.docker.enable [
+
"/var/lib/docker"
+
"/var/lib/containers"
+
])
];
-
files = ["/etc/machine-id"];
+
files = [ "/etc/machine-id" ];
};
};
# warframe
-
networking.firewall.allowedUDPPorts = [4990 4991 4992 4993 4994 4995];
+
networking.firewall.allowedUDPPorts = [
+
4990
+
4991
+
4992
+
4993
+
4994
+
4995
+
];
# musikcube
-
networking.firewall.allowedTCPPorts = [7905 7906] ++ [6695 6696 6697 6698 6699] ++ [50300];
+
networking.firewall.allowedTCPPorts =
+
[
+
7905
+
7906
+
]
+
++ [
+
6695
+
6696
+
6697
+
6698
+
6699
+
]
+
++ [ 50300 ];
# for tailscale
networking.firewall.checkReversePath = "loose";
+9 -6
hosts/tkaronto/modules/boot.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
boot = {
tmp.useTmpfs = true;
loader = {
···
systemd-boot.configurationLimit = 10;
};
kernelPackages = pkgs.linuxPackages_zen;
-
supportedFilesystems = ["f2fs"];
+
supportedFilesystems = [ "f2fs" ];
initrd = {
availableKernelModules = [
"nvme"
···
"usbhid"
"sd_mod"
];
-
kernelModules = ["amdgpu"];
+
kernelModules = [ "amdgpu" ];
+
};
+
kernelModules = [ "kvm-amd" ];
+
extraModulePackages = [ ];
+
kernel.sysctl = {
+
"fs.inotify.max_user_watches" = 524288;
};
-
kernelModules = ["kvm-amd"];
-
extraModulePackages = [];
-
kernel.sysctl = {"fs.inotify.max_user_watches" = 524288;};
};
}
+17 -5
hosts/tkaronto/modules/fs.nix
···
-
{config, ...}: let
+
{ config, ... }:
+
let
byLabel = label: "/dev/disk/by-label/${label}";
-
f2fsOptions = ["compress_algorithm=zstd:6" "compress_chksum" "atgc" "gc_merge" "lazytime"];
-
in {
+
f2fsOptions = [
+
"compress_algorithm=zstd:6"
+
"compress_chksum"
+
"atgc"
+
"gc_merge"
+
"lazytime"
+
];
+
in
+
{
fileSystems."/" = {
device = "none";
fsType = "tmpfs";
-
options = ["defaults" "size=2G" "mode=755"];
+
options = [
+
"defaults"
+
"size=2G"
+
"mode=755"
+
];
};
fileSystems."/nix" = {
device = byLabel "NIX";
···
fsType = "vfat";
};
-
swapDevices = [];
+
swapDevices = [ ];
zramSwap = {
enable = true;
algorithm = "zstd";
+3 -2
hosts/tkaronto/modules/iphone.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
services.usbmuxd.enable = true;
-
environment.systemPackages = [pkgs.libimobiledevice];
+
environment.systemPackages = [ pkgs.libimobiledevice ];
}
+1 -1
hosts/tkaronto/modules/secrets.nix
···
{
-
age.identityPaths = ["/persist/keys/ssh_key"];
+
age.identityPaths = [ "/persist/keys/ssh_key" ];
age.secrets.nixGithubAccessToken.file = ../../../secrets/nixGithubAccessToken.age;
age.secrets.wgTkarontoKey = {
+3 -2
hosts/tkaronto/modules/wireguard.nix
···
-
{config, ...}: {
+
{ config, ... }:
+
{
systemd.network.enable = true;
systemd.network.netdevs."wg0" = {
enable = true;
···
{
wireguardPeerConfig = {
PublicKey = builtins.readFile ./wgWolumondeKey.pub;
-
AllowedIPs = ["10.99.0.1/32"];
+
AllowedIPs = [ "10.99.0.1/32" ];
Endpoint = "${builtins.readFile ./wgWolumondeIp}:51820";
PersistentKeepalive = 25;
};
+14 -10
hosts/wolumonde/default.nix
···
tlib,
pkgs,
...
-
}: {
-
imports =
-
[
-
inputs.agenix.nixosModules.default
-
# inputs.nixtopo.nixosModules.default
-
]
-
++ (tlib.importFolder (toString ./modules));
+
}:
+
{
+
imports = [
+
inputs.agenix.nixosModules.default
+
# inputs.nixtopo.nixosModules.default
+
] ++ (tlib.importFolder (toString ./modules));
-
environment.systemPackages = [pkgs.magic-wormhole-rs];
+
environment.systemPackages = [ pkgs.magic-wormhole-rs ];
boot.tmp.cleanOnBoot = true;
zramSwap.enable = true;
···
# firewall stuffs
networking.firewall = {
enable = true;
-
allowedTCPPorts = [22 80 443 5005];
-
allowedUDPPortRanges = [];
+
allowedTCPPorts = [
+
22
+
80
+
443
+
5005
+
];
+
allowedUDPPortRanges = [ ];
};
virtualisation.docker.enable = true;
+2 -2
hosts/wolumonde/modules/arpa.nix
···
-
{pkgs, config, ...}:
+
{ pkgs, config, ... }:
let
index = pkgs.writeText "index.txt" ''
hi there~
···
/dig +short TXT 9.0.0.0.8.e.f.1.5.0.7.4.0.1.0.0.2.ip6.arpa/
'';
-
root = pkgs.runCommand "root" {} ''
+
root = pkgs.runCommand "root" { } ''
mkdir -p $out
ln -s ${index} $out/index.txt
'';
+35 -25
hosts/wolumonde/modules/atproto.nix
···
-
{pkgs, lib, ...}: let
+
{ pkgs, lib, ... }:
+
let
mkFileCopy = name: file: "cp ${file} $out/${name}";
-
mkWellKnownDir = files: pkgs.runCommand "well-known" {} ''
-
mkdir -p $out
-
${lib.concatStringsSep "\n" (lib.mapAttrsToList mkFileCopy files)}
-
'';
+
mkWellKnownDir =
+
files:
+
pkgs.runCommand "well-known" { } ''
+
mkdir -p $out
+
${lib.concatStringsSep "\n" (lib.mapAttrsToList mkFileCopy files)}
+
'';
mkWellKnownCfg = files: {
locations."/.well-known/".extraConfig = ''
add_header content-type text/plain;
···
'';
};
mkDidWebCfg = domain: {
-
"${domain}" = (mkWellKnownCfg {
-
"did.json" = ../../../secrets/${domain}.did;
-
"atproto-did" = pkgs.writeText "server" "did:web:${domain}";
-
}) // (lib.optionalAttrs (lib.hasSuffix "gaze.systems" domain) {
-
useACMEHost = "gaze.systems";
-
forceSSL = true;
-
});
+
"${domain}" =
+
(mkWellKnownCfg {
+
"did.json" = ../../../secrets/${domain}.did;
+
"atproto-did" = pkgs.writeText "server" "did:web:${domain}";
+
})
+
// (lib.optionalAttrs (lib.hasSuffix "gaze.systems" domain) {
+
useACMEHost = "gaze.systems";
+
forceSSL = true;
+
});
};
-
in {
-
services.nginx.virtualHosts = {
-
"gaze.systems" = (mkWellKnownCfg {
-
"atproto-did" = pkgs.writeText "server" "did:plc:dfl62fgb7wtjj3fcbb72naae";
-
}) // {
-
useACMEHost = "gaze.systems";
-
forceSSL = true;
-
};
-
# "9.0.0.0.8.e.f.1.5.0.7.4.0.1.0.0.2.ip6.arpa" = mkWellKnownCfg {
-
# "atproto-did" = pkgs.writeText "server" "did:plc:dfl62fgb7wtjj3fcbb72naae";
-
# };
-
} // (mkDidWebCfg "dawn.gaze.systems")
-
// (mkDidWebCfg "guestbook.gaze.systems");
+
in
+
{
+
services.nginx.virtualHosts =
+
{
+
"gaze.systems" =
+
(mkWellKnownCfg {
+
"atproto-did" = pkgs.writeText "server" "did:plc:dfl62fgb7wtjj3fcbb72naae";
+
})
+
// {
+
useACMEHost = "gaze.systems";
+
forceSSL = true;
+
};
+
# "9.0.0.0.8.e.f.1.5.0.7.4.0.1.0.0.2.ip6.arpa" = mkWellKnownCfg {
+
# "atproto-did" = pkgs.writeText "server" "did:plc:dfl62fgb7wtjj3fcbb72naae";
+
# };
+
}
+
// (mkDidWebCfg "dawn.gaze.systems")
+
// (mkDidWebCfg "guestbook.gaze.systems");
# // (mkDidWebCfg "9.0.0.0.8.e.f.1.5.0.7.4.0.1.0.0.2.ip6.arpa");
}
+7 -5
hosts/wolumonde/modules/bernbot.nix
···
pkgs,
lib,
...
-
}: let
+
}:
+
let
bernbotPkg = inputs.bernbot.packages.${pkgs.system}.bernbot-release;
-
in {
+
in
+
{
systemd.services.bernbot = {
description = "bernbot";
-
wantedBy = ["multi-user.target"];
-
after = ["network.target"];
+
wantedBy = [ "multi-user.target" ];
+
after = [ "network.target" ];
serviceConfig = lib.mkMerge [
{
User = "bernbot";
···
isSystemUser = true;
group = "bernbot";
};
-
users.groups.bernbot = {};
+
users.groups.bernbot = { };
}
+10 -5
hosts/wolumonde/modules/blog.nix
···
pkgs,
inputs,
...
-
}: let
+
}:
+
let
PUBLIC_BASE_URL = "https://gaze.systems";
pkg = inputs.blog.packages.${pkgs.system}.default.overrideAttrs (old: {
inherit PUBLIC_BASE_URL;
});
port = 3003;
-
in {
+
in
+
{
users.users.website = {
isSystemUser = true;
group = "website";
};
-
users.groups.website = {};
+
users.groups.website = { };
systemd.services.website = {
description = "website";
-
wantedBy = ["multi-user.target"];
-
after = ["network.target" "guestbook.service"];
+
wantedBy = [ "multi-user.target" ];
+
after = [
+
"network.target"
+
"guestbook.service"
+
];
environment = {
HOME = "/var/lib/website";
ORIGIN = PUBLIC_BASE_URL;
+2 -1
hosts/wolumonde/modules/forgejo.nix
···
-
{pkgs, config, ...}: {
+
{ pkgs, config, ... }:
+
{
services.forgejo = {
enable = true;
package = pkgs.forgejo;
+9 -4
hosts/wolumonde/modules/hardware-configuration.nix
···
-
{modulesPath, ...}: {
-
imports = [(modulesPath + "/profiles/qemu-guest.nix")];
+
{ modulesPath, ... }:
+
{
+
imports = [ (modulesPath + "/profiles/qemu-guest.nix") ];
boot.loader.grub.device = "/dev/sda";
-
boot.initrd.availableKernelModules = ["ata_piix" "uhci_hcd" "xen_blkfront"];
-
boot.initrd.kernelModules = ["nvme"];
+
boot.initrd.availableKernelModules = [
+
"ata_piix"
+
"uhci_hcd"
+
"xen_blkfront"
+
];
+
boot.initrd.kernelModules = [ "nvme" ];
fileSystems."/" = {
device = "/dev/sda1";
fsType = "ext4";
+4 -2
hosts/wolumonde/modules/hedgedoc.nix
···
-
{config, ...}: {
+
{ config, ... }:
+
{
services.hedgedoc = {
enable = true;
settings = {
···
forceSSL = true;
quic = true;
kTLS = true;
-
locations."/".proxyPass = "http://${config.services.hedgedoc.settings.host}:${toString config.services.hedgedoc.settings.port}";
+
locations."/".proxyPass =
+
"http://${config.services.hedgedoc.settings.host}:${toString config.services.hedgedoc.settings.port}";
};
}
+7 -5
hosts/wolumonde/modules/limbusart.nix
···
pkgs,
lib,
...
-
}: let
+
}:
+
let
pkg = inputs.limbusart.packages.${pkgs.system}.default;
-
in {
+
in
+
{
systemd.services.limbusart = {
description = "limbusart";
-
wantedBy = ["multi-user.target"];
-
after = ["network.target"];
+
wantedBy = [ "multi-user.target" ];
+
after = [ "network.target" ];
serviceConfig = lib.mkMerge [
{
User = "limbusart";
···
isSystemUser = true;
group = "limbusart";
};
-
users.groups.limbusart = {};
+
users.groups.limbusart = { };
services.nginx.virtualHosts."pmart.gaze.systems" = {
useACMEHost = "gaze.systems";
+3 -2
hosts/wolumonde/modules/nginx.nix
···
-
{inputs, pkgs, ...}: {
+
{ inputs, pkgs, ... }:
+
{
services.nginx = {
enable = true;
package = pkgs.nginxQuic;
···
recommendedProxySettings = true;
};
-
users.users.nginx.extraGroups = ["acme"];
+
users.users.nginx.extraGroups = [ "acme" ];
security.acme = {
acceptTerms = true;
+2 -1
hosts/wolumonde/modules/nixinate.nix
···
-
{...}: {
+
{ ... }:
+
{
_module.args.nixinate = {
host = "gaze.systems";
sshUser = "root";
+10 -9
hosts/wolumonde/modules/pds.nix
···
-
{ config, ... }: {
+
{ config, ... }:
+
{
services.nginx.virtualHosts.${config.services.pds.settings.PDS_HOSTNAME} = {
useACMEHost = "gaze.systems";
forceSSL = true;
···
PDS_RATE_LIMITS_ENABLED = "true";
PDS_INVITE_REQUIRED = "true";
-
PDS_DID_PLC_URL="https://plc.directory";
-
PDS_BSKY_APP_VIEW_URL="https://api.bsky.app";
-
PDS_BSKY_APP_VIEW_DID="did:web:api.bsky.app";
-
PDS_REPORT_SERVICE_URL="https://mod.bsky.app";
-
PDS_REPORT_SERVICE_DID="did:plc:ar7c4by46qjdydhdevvrndac";
-
PDS_CRAWLERS="https://bsky.network";
+
PDS_DID_PLC_URL = "https://plc.directory";
+
PDS_BSKY_APP_VIEW_URL = "https://api.bsky.app";
+
PDS_BSKY_APP_VIEW_DID = "did:web:api.bsky.app";
+
PDS_REPORT_SERVICE_URL = "https://mod.bsky.app";
+
PDS_REPORT_SERVICE_DID = "did:plc:ar7c4by46qjdydhdevvrndac";
+
PDS_CRAWLERS = "https://bsky.network";
};
-
environmentFiles = [config.age.secrets.pdsConfig.path];
+
environmentFiles = [ config.age.secrets.pdsConfig.path ];
};
# virtualisation = {
···
# autoStart = true;
# environmentFiles = [ ./pds.env config.age.secrets.pdsConfig.path ];
# ports = [ "1334:1334" ];
-
# volumes = [
+
# volumes = [
# "/var/lib/pds:/pds"
# ];
# extraOptions = [
+2 -1
hosts/wolumonde/modules/secrets.nix
···
-
{lib, ...}: {
+
{ lib, ... }:
+
{
age.secrets.bernbotToken.file = ../../../secrets/bernbotToken.age;
age.secrets.websiteConfig.file = ../../../secrets/websiteConfig.age;
age.secrets.pdsConfig.file = ../../../secrets/pdsConfig.age;
+2 -1
hosts/wolumonde/modules/ssh.nix
···
-
{inputs, ...}: {
+
{ inputs, ... }:
+
{
services.fail2ban.enable = true;
services.openssh = {
enable = true;
+1 -1
hosts/wolumonde/modules/tailscale.nix
···
{
services.tailscale.enable = true;
-
}
+
}
+2 -1
hosts/wolumonde/modules/webhook.nix
···
-
{config, tlib, ...}: {
+
{ config, tlib, ... }:
+
{
imports = tlib.importFolder ./webhooks;
services.webhook = {
+7 -3
hosts/wolumonde/modules/webhooks/deploy-wolumonde.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
services.webhook.hooks."deploy-wolumonde" = {
execute-command = "${pkgs.curl}/bin/curl";
-
pass-arguments-to-command = builtins.map (n: {source = "string"; name = n;}) ["http://higashi:9000/hooks/deploy-wolumonde"];
+
pass-arguments-to-command = builtins.map (n: {
+
source = "string";
+
name = n;
+
}) [ "http://higashi:9000/hooks/deploy-wolumonde" ];
};
-
}
+
}
+9 -10
hosts/wsl/default.nix
···
pkgs,
inputs,
...
-
}: {
-
imports =
-
[
-
../../users/root
-
../../users/firewatch
-
inputs.nixos-wsl.nixosModules.wsl
-
inputs.agenix.nixosModules.default
-
]
-
++ (tlib.importFolder (toString ./modules));
+
}:
+
{
+
imports = [
+
../../users/root
+
../../users/firewatch
+
inputs.nixos-wsl.nixosModules.wsl
+
inputs.agenix.nixosModules.default
+
] ++ (tlib.importFolder (toString ./modules));
wsl.enable = true;
wsl.defaultUser = "firewatch";
···
networking.hostName = "wsl";
-
environment.systemPackages = [pkgs.wget];
+
environment.systemPackages = [ pkgs.wget ];
environment.sessionVariables = {
FLAKE = "/home/firewatch/ark";
};
+1 -1
hosts/wsl/modules/secrets.nix
···
{
-
age.identityPaths = ["/home/firewatch/.ssh/id_rsa"];
+
age.identityPaths = [ "/home/firewatch/.ssh/id_rsa" ];
age.secrets.nixGithubAccessToken.file = ../../../secrets/nixGithubAccessToken.age;
}
+17 -15
lib/default.nix
···
defaultSystems = import ./systems.nix;
genSystems = lib.genAttrs self.defaultSystems;
-
pkgBin = pkg:
-
if (pkg.meta or {}) ? mainProgram
-
then "${pkg}/bin/${pkg.meta.mainProgram}"
-
else "${pkg}/bin/${pkg.pname}";
+
pkgBin =
+
pkg:
+
if (pkg.meta or { }) ? mainProgram then
+
"${pkg}/bin/${pkg.meta.mainProgram}"
+
else
+
"${pkg}/bin/${pkg.pname}";
-
prefixStrings = prefix: strings:
-
lib.forEach strings (string: "${prefix}${string}");
+
prefixStrings = prefix: strings: lib.forEach strings (string: "${prefix}${string}");
-
importFolder = modules: let
-
b = builtins;
-
files = b.readDir modules;
-
fileNames = b.attrNames files;
-
filesToImport =
-
b.map
-
(name: "${modules}/${name}")
-
(b.filter (name: b.match ".*\.nix" name != null) fileNames);
-
in
+
importFolder =
+
modules:
+
let
+
b = builtins;
+
files = b.readDir modules;
+
fileNames = b.attrNames files;
+
filesToImport = b.map (name: "${modules}/${name}") (
+
b.filter (name: b.match ".*\.nix" name != null) fileNames
+
);
+
in
filesToImport;
})
+1 -1
lib/systems.nix
···
-
["x86_64-linux"]
+
[ "x86_64-linux" ]
+6 -2
locale/default.nix
···
-
{...}: {
+
{ ... }:
+
{
i18n = {
defaultLocale = "en_US.UTF-8";
-
supportedLocales = ["en_US.UTF-8/UTF-8" "tr_TR.UTF-8/UTF-8"];
+
supportedLocales = [
+
"en_US.UTF-8/UTF-8"
+
"tr_TR.UTF-8/UTF-8"
+
];
};
time.timeZone = "Turkey";
services.xserver.xkb.layout = "us";
+4 -2
modules/ananicy/default.nix
···
-
{lib, ...}: let
+
{ lib, ... }:
+
let
l = lib // builtins;
mkRule = name: type: {
inherit name type;
};
-
in {
+
in
+
{
services.ananicy = {
enable = true;
extraRules = [
+56 -43
modules/base/default.nix
···
lib,
tlib,
...
-
}: let
+
}:
+
let
inherit (lib) fileContents mkIf;
coreBin = v: "${pkgs.coreutils}/bin/${v}";
nixBin = "${config.nix.package}/bin/nix";
pkgBin = tlib.pkgBin;
-
in {
+
in
+
{
imports = [
./nix.nix
./hm-system-defaults.nix
···
git
git-crypt
];
-
shellAliases = let
-
ifSudo = string: mkIf config.security.sudo.enable string;
-
inherit (pkgs) git bat eza du-dust;
-
in {
-
g = pkgBin git;
-
git-optimize = "${pkgBin git} gc --aggressive --prune=now";
-
cat = "${pkgBin bat} -pp --theme=base16";
-
c = "cat";
-
du = "${pkgBin du-dust}";
-
df = "${coreBin "df"} -h";
-
free = "${pkgs.procps}/bin/free -h";
-
ls = pkgBin eza;
-
l = "${pkgBin eza} -lhg";
-
la = "${pkgBin eza} -lhg -a";
-
t = "${pkgBin eza} -lhg -T";
-
ta = "${pkgBin eza} -lhg -a -T";
-
n = nixBin;
-
nb = "${nixBin} build";
-
nf = "${nixBin} flake";
-
nfu = "${nixBin} flake update";
-
nfui = "${nixBin} flake update";
-
nfs = "${nixBin} flake show";
-
nsh = "${nixBin} shell";
-
nix-store-refs = "nix-store -qR";
-
nosrs = ifSudo "sudo nixos-rebuild --fast switch";
-
nosrb = ifSudo "sudo nixos-rebuild --fast boot";
-
nosrt = ifSudo "sudo nixos-rebuild --fast test";
-
ngc = ifSudo "sudo nix-collect-garbage";
-
ngcdo = ifSudo "sudo nix-collect-garbage --delete-old";
-
top = "${pkgs.bottom}/bin/btm";
-
myip = "${pkgs.dnsutils}/bin/dig +short myip.opendns.com @208.67.222.222 2>&1";
-
mn = let
-
manix_preview = "manix '{}' | sed 's/type: /> type: /g' | bat -l Markdown --color=always --plain";
-
in ''manix "" | rg '^# ' | sed 's/^# \(.*\) (.*/\1/;s/ (.*//;s/^# //' | sk --preview="${manix_preview}" | xargs manix'';
-
# systemd
-
ctl = "systemctl";
-
stl = ifSudo "s systemctl";
-
utl = "systemctl --user";
-
jtl = "journalctl";
-
};
+
shellAliases =
+
let
+
ifSudo = string: mkIf config.security.sudo.enable string;
+
inherit (pkgs)
+
git
+
bat
+
eza
+
du-dust
+
;
+
in
+
{
+
g = pkgBin git;
+
git-optimize = "${pkgBin git} gc --aggressive --prune=now";
+
cat = "${pkgBin bat} -pp --theme=base16";
+
c = "cat";
+
du = "${pkgBin du-dust}";
+
df = "${coreBin "df"} -h";
+
free = "${pkgs.procps}/bin/free -h";
+
ls = pkgBin eza;
+
l = "${pkgBin eza} -lhg";
+
la = "${pkgBin eza} -lhg -a";
+
t = "${pkgBin eza} -lhg -T";
+
ta = "${pkgBin eza} -lhg -a -T";
+
n = nixBin;
+
nb = "${nixBin} build";
+
nf = "${nixBin} flake";
+
nfu = "${nixBin} flake update";
+
nfui = "${nixBin} flake update";
+
nfs = "${nixBin} flake show";
+
nsh = "${nixBin} shell";
+
nix-store-refs = "nix-store -qR";
+
nosrs = ifSudo "sudo nixos-rebuild --fast switch";
+
nosrb = ifSudo "sudo nixos-rebuild --fast boot";
+
nosrt = ifSudo "sudo nixos-rebuild --fast test";
+
ngc = ifSudo "sudo nix-collect-garbage";
+
ngcdo = ifSudo "sudo nix-collect-garbage --delete-old";
+
top = "${pkgs.bottom}/bin/btm";
+
myip = "${pkgs.dnsutils}/bin/dig +short myip.opendns.com @208.67.222.222 2>&1";
+
mn =
+
let
+
manix_preview = "manix '{}' | sed 's/type: /> type: /g' | bat -l Markdown --color=always --plain";
+
in
+
''manix "" | rg '^# ' | sed 's/^# \(.*\) (.*/\1/;s/ (.*//;s/^# //' | sk --preview="${manix_preview}" | xargs manix'';
+
# systemd
+
ctl = "systemctl";
+
stl = ifSudo "s systemctl";
+
utl = "systemctl --user";
+
jtl = "journalctl";
+
};
};
system.activationScripts.diff = ''
if [ -z "$systemConfig" ]; then
···
command-not-found.enable = true;
git = {
enable = true;
-
config = {safe.directory = ["/etc/nixos"];};
+
config = {
+
safe.directory = [ "/etc/nixos" ];
+
};
};
};
}
+21 -18
modules/base/hm-system-defaults.nix
···
inputs,
tlib,
...
-
}: {
+
}:
+
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.sharedModules = [
···
xdg.configFile."nix/nix.conf".source = config.environment.etc."nix/nix.conf".source;
# xdg.configFile."nix/netrc".source = config.environment.etc."nix/netrc".source;
}
-
({
-
config,
-
pkgs,
-
lib,
-
...
-
}: {
-
home.packages = [
-
(
-
pkgs.writeShellScriptBin "apply-hm-env" ''
-
${lib.optionalString (config.home.sessionPath != []) ''
+
(
+
{
+
config,
+
pkgs,
+
lib,
+
...
+
}:
+
{
+
home.packages = [
+
(pkgs.writeShellScriptBin "apply-hm-env" ''
+
${lib.optionalString (config.home.sessionPath != [ ]) ''
export PATH=${builtins.concatStringsSep ":" config.home.sessionPath}:$PATH
''}
-
${builtins.concatStringsSep "\n" (lib.mapAttrsToList (k: v: ''
+
${builtins.concatStringsSep "\n" (
+
lib.mapAttrsToList (k: v: ''
export ${k}="${builtins.toString v}"
-
'')
-
config.home.sessionVariables)}
+
'') config.home.sessionVariables
+
)}
${config.home.sessionVariablesExtra}
exec "$@"
-
''
-
)
-
];
-
})
+
'')
+
];
+
}
+
)
];
home-manager.extraSpecialArgs = {
inherit inputs tlib;
+12 -8
modules/base/nix.nix
···
lib,
inputs,
...
-
}: {
+
}:
+
{
nix = {
-
registry =
-
builtins.mapAttrs
-
(_: v: {flake = v;})
-
(lib.filterAttrs (_: v: v ? outputs) inputs);
+
registry = builtins.mapAttrs (_: v: { flake = v; }) (lib.filterAttrs (_: v: v ? outputs) inputs);
package = pkgs.lixPackageSets.latest.lix;
gc.automatic = false;
optimise.automatic = true;
···
extra-experimental-features = nix-command flakes
builders-use-substitutes = true
'';
-
nixPath = ["nixpkgs=${inputs.nixpkgs}" "home-manager=${inputs.home}"];
+
nixPath = [
+
"nixpkgs=${inputs.nixpkgs}"
+
"home-manager=${inputs.home}"
+
];
};
nix.settings = {
sandbox = true;
-
allowed-users = ["@wheel"];
-
trusted-users = ["root" "@wheel"];
+
allowed-users = [ "@wheel" ];
+
trusted-users = [
+
"root"
+
"@wheel"
+
];
auto-optimise-store = true;
};
}
+5 -3
modules/cachix/default.nix
···
pkgs,
lib,
...
-
}: let
+
}:
+
let
folder = ./.;
toImport = name: value: folder + ("/" + name);
filterCaches = key: value: value == "regular" && lib.hasSuffix ".nix" key && key != "default.nix";
imports = lib.mapAttrsToList toImport (lib.filterAttrs filterCaches (builtins.readDir folder));
-
in {
+
in
+
{
inherit imports;
-
nix.settings.substituters = ["https://cache.nixos.org/"];
+
nix.settings.substituters = [ "https://cache.nixos.org/" ];
}
+2 -2
modules/cachix/helix.nix
···
{
nix.settings = {
-
substituters = ["https://helix.cachix.org"];
-
trusted-public-keys = ["helix.cachix.org-1:ejp9KQpR1FBI2onstMQ34yogDm4OgU2ru6lIwPvuCVs="];
+
substituters = [ "https://helix.cachix.org" ];
+
trusted-public-keys = [ "helix.cachix.org-1:ejp9KQpR1FBI2onstMQ34yogDm4OgU2ru6lIwPvuCVs=" ];
};
}
+2 -2
modules/cachix/nix-community.nix
···
{
nix.settings = {
-
substituters = ["https://nix-community.cachix.org"];
-
trusted-public-keys = ["nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="];
+
substituters = [ "https://nix-community.cachix.org" ];
+
trusted-public-keys = [ "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" ];
};
}
+2 -1
modules/de/budgie/default.nix
···
pkgs,
lib,
...
-
}: {
+
}:
+
{
services.xserver = {
enable = true;
desktopManager = {
+2 -1
modules/de/gnome/default.nix
···
pkgs,
lib,
...
-
}: {
+
}:
+
{
services.gnome = {
gnome-keyring.enable = true;
core-shell.enable = true;
+2 -1
modules/de/greetd/default.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
services.greetd = {
enable = true;
settings = {
+7 -3
modules/develop/default.nix
···
-
{pkgs, ...}: {
-
imports = [./editor];
-
environment.systemPackages = with pkgs; [git tokei];
+
{ pkgs, ... }:
+
{
+
imports = [ ./editor ];
+
environment.systemPackages = with pkgs; [
+
git
+
tokei
+
];
documentation.dev.enable = true;
}
+8 -3
modules/develop/editor/default.nix
···
-
{pkgs, ...}: {
-
imports = [./helix.nix];
-
environment.systemPackages = with pkgs; [treefmt nixd nixfmt-rfc-style];
+
{ pkgs, ... }:
+
{
+
imports = [ ./helix.nix ];
+
environment.systemPackages = with pkgs; [
+
treefmt
+
nixd
+
nixfmt-rfc-style
+
];
}
+8 -4
modules/develop/editor/helix.nix
···
-
{pkgs, ...}: let
+
{ pkgs, ... }:
+
let
pkg = pkgs.helix;
bin = "${pkg}/bin/hx";
-
in {
-
environment.systemPackages = [pkg];
+
in
+
{
+
environment.systemPackages = [ pkg ];
environment.sessionVariables = {
EDITOR = bin;
VISUAL = bin;
};
-
environment.shellAliases = {e = bin;};
+
environment.shellAliases = {
+
e = bin;
+
};
}
+8 -4
modules/develop/editor/kakoune.nix
···
-
{pkgs, ...}: let
+
{ pkgs, ... }:
+
let
pkg = pkgs.kakoune-unwrapped;
-
in {
-
environment.systemPackages = [pkg];
+
in
+
{
+
environment.systemPackages = [ pkg ];
environment.sessionVariables = {
EDITOR = "${pkg}/bin/kak";
VISUAL = "${pkg}/bin/kak";
};
-
environment.shellAliases = {k = "${pkg}/bin/kak";};
+
environment.shellAliases = {
+
k = "${pkg}/bin/kak";
+
};
}
+7 -3
modules/develop/nixbuild/default.nix
···
-
{config, ...}: {
+
{ config, ... }:
+
{
programs.ssh.extraConfig = ''
Host eu.nixbuild.net
PubkeyAcceptedKeyTypes ssh-ed25519
···
programs.ssh.knownHosts = {
nixbuild = {
-
hostNames = ["eu.nixbuild.net"];
+
hostNames = [ "eu.nixbuild.net" ];
publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPIQCZc54poJ8vqawd8TraNryQeJnvH1eLpIDgbiqymM";
};
};
···
hostName = "eu.nixbuild.net";
system = "x86_64-linux";
maxJobs = 100;
-
supportedFeatures = ["benchmark" "big-parallel"];
+
supportedFeatures = [
+
"benchmark"
+
"big-parallel"
+
];
}
];
};
+2 -1
modules/flatpak/default.nix
···
-
{config, ...}: {
+
{ config, ... }:
+
{
services.flatpak.enable = true;
environment.persistence."${config.system.persistDir}".directories = [
"/var/lib/flatpak"
+4 -2
modules/gamemode/default.nix
···
inputs,
lib,
...
-
}: let
+
}:
+
let
programs = inputs.hyprland.packages.${pkgs.system}.default;
startscript = pkgs.writeShellScript "gamemode-start" ''
···
export HYPRLAND_INSTANCE_SIGNATURE=$(ls -w1 /tmp/hypr | tail -1)
hyprctl --batch 'keyword decoration:blur 1 ; keyword animations:enabled 1 ; keyword misc:no_vfr 0'
'';
-
in {
+
in
+
{
programs.gamemode = {
enable = true;
enableRenice = true;
+2 -1
modules/github.nix
···
-
{config, ...}: {
+
{ config, ... }:
+
{
nix.extraOptions = ''
!include ${config.age.secrets.nixGithubAccessToken.path}
'';
+4 -3
modules/gnome-boxes/default.nix
···
-
{pkgs, ...}: {
-
imports = [../libvirtd];
-
environment.systemPackages = [pkgs.gnome.gnome-boxes];
+
{ pkgs, ... }:
+
{
+
imports = [ ../libvirtd ];
+
environment.systemPackages = [ pkgs.gnome.gnome-boxes ];
}
+2 -1
modules/libvirtd/default.nix
···
-
{config, ...}: {
+
{ config, ... }:
+
{
virtualisation.libvirtd.enable = true;
environment.persistence."${config.system.persistDir}".directories = [
"/var/lib/libvirt"
+1 -1
modules/network/default.nix
···
{
-
imports = [./networkmanager];
+
imports = [ ./networkmanager ];
systemd.network.wait-online.enable = false;
}
+6 -2
modules/network/dns/cloudflare.nix
···
-
{lib, ...}: {
+
{ lib, ... }:
+
{
networking.resolvconf.useLocalResolver = true;
networking.networkmanager.dns = lib.mkForce "none";
services.dnscrypt-proxy2 = {
enable = true;
settings = {
-
server_names = ["cloudflare" "cloudflare-ipv6"];
+
server_names = [
+
"cloudflare"
+
"cloudflare-ipv6"
+
];
};
};
}
+1 -1
modules/network/dns/default.nix
···
{
-
imports = [./cloudflare.nix];
+
imports = [ ./cloudflare.nix ];
}
+4 -1
modules/network/dns/nextdns.nix
···
networking.resolvconf.useLocalResolver = true;
services.nextdns = {
enable = true;
-
arguments = ["-config" "75e43d"];
+
arguments = [
+
"-config"
+
"75e43d"
+
];
};
}
+1 -1
modules/network/dns/stubby/default.nix
···
{
-
imports = [./nextdns.nix];
+
imports = [ ./nextdns.nix ];
networking.networkmanager.dns = "none";
services.stubby.enable = true;
}
+14 -12
modules/network/dns/stubby/nextdns.nix
···
{
services.stubby = {
roundRobinUpstreams = false;
-
upstreamServers = let
-
nextDnsId = "75e43d";
-
in ''
-
- address_data: 45.90.28.0
-
tls_auth_name: "${nextDnsId}.dns1.nextdns.io"
-
- address_data: 2a07:a8c0::0
-
tls_auth_name: "${nextDnsId}.dns1.nextdns.io"
-
- address_data: 45.90.30.0
-
tls_auth_name: "${nextDnsId}.dns2.nextdns.io"
-
- address_data: 2a07:a8c1::0
-
tls_auth_name: "${nextDnsId}.dns2.nextdns.io"
-
'';
+
upstreamServers =
+
let
+
nextDnsId = "75e43d";
+
in
+
''
+
- address_data: 45.90.28.0
+
tls_auth_name: "${nextDnsId}.dns1.nextdns.io"
+
- address_data: 2a07:a8c0::0
+
tls_auth_name: "${nextDnsId}.dns1.nextdns.io"
+
- address_data: 45.90.30.0
+
tls_auth_name: "${nextDnsId}.dns2.nextdns.io"
+
- address_data: 2a07:a8c1::0
+
tls_auth_name: "${nextDnsId}.dns2.nextdns.io"
+
'';
};
}
+6 -2
modules/network/iwd/default.nix
···
networking.wireless.iwd = {
enable = true;
settings = {
-
Network = {EnableIPv6 = true;};
-
Settings = {AutoConnect = true;};
+
Network = {
+
EnableIPv6 = true;
+
};
+
Settings = {
+
AutoConnect = true;
+
};
};
};
networking.networkmanager.wifi.backend = "iwd";
+7 -3
modules/network/networkmanager/default.nix
···
-
{config, ...}: {
-
imports = [../dns ../iwd];
+
{ config, ... }:
+
{
+
imports = [
+
../dns
+
../iwd
+
];
networking.networkmanager = {
enable = true;
wifi.powersave = true;
};
environment.persistence."${config.system.persistDir}" = {
-
directories = ["/etc/NetworkManager/system-connections"];
+
directories = [ "/etc/NetworkManager/system-connections" ];
};
}
+1 -1
modules/network/wpa_supplicant.nix
···
{
-
imports = [./dns];
+
imports = [ ./dns ];
networking.wireless = {
enable = true;
userControlled.enable = true;
+2 -1
modules/persist/default.nix
···
-
{lib, ...}: {
+
{ lib, ... }:
+
{
options.system.persistDir = lib.mkOption {
type = lib.types.str;
};
+3 -2
modules/persist/null.nix
···
-
{lib, ...}: {
-
imports = [./default.nix];
+
{ lib, ... }:
+
{
+
imports = [ ./default.nix ];
config = {
system.persistDir = "null";
+3 -2
modules/syncthing/default.nix
···
config,
inputs,
...
-
}: {
-
users.users.syncthing.extraGroups = ["users"];
+
}:
+
{
+
users.users.syncthing.extraGroups = [ "users" ];
services.syncthing = {
enable = true;
devices.redmi-phone = {
+16 -27
pkgs-set/default.nix
···
lib,
tlib,
...
-
}: let
+
}:
+
let
l = lib;
-
overlays =
-
l.mapAttrsToList
-
(
-
name: _: let
-
o = import "${./.}/overlays/${name}";
-
in
-
if (l.functionArgs o) ? inputs
-
then o {inherit inputs;}
-
else o
-
)
-
(l.readDir ./overlays);
-
newPkgs =
-
l.mapAttrsToList
-
(
-
name: _: final: prev: {
-
${l.removeSuffix ".nix" name} =
-
final.callPackage
-
"${./pkgs}/${name}"
-
{inherit inputs tlib;};
-
}
-
)
-
(l.readDir ./pkgs);
+
overlays = l.mapAttrsToList (
+
name: _:
+
let
+
o = import "${./.}/overlays/${name}";
+
in
+
if (l.functionArgs o) ? inputs then o { inherit inputs; } else o
+
) (l.readDir ./overlays);
+
newPkgs = l.mapAttrsToList (name: _: final: prev: {
+
${l.removeSuffix ".nix" name} = final.callPackage "${./pkgs}/${name}" { inherit inputs tlib; };
+
}) (l.readDir ./pkgs);
pkgs = import inputs.nixpkgs {
inherit system;
config.allowUnfree = true;
···
};
pkgsToExport = import ./pkgs-to-export.nix pkgs;
in
-
pkgs
-
// {
-
_exported = pkgsToExport;
-
}
+
pkgs
+
// {
+
_exported = pkgsToExport;
+
}
+2 -1
pkgs-set/overlays/agenix.nix
···
-
{inputs}: final: prev: {
+
{ inputs }:
+
final: prev: {
agenix = inputs.agenix.packages."${final.system}".agenix;
}
+8 -1
pkgs-set/overlays/calf.nix
···
rev = "024e9deab2d32b26e90b556d36d9c74f6b0aeb17";
sha256 = "sha256-av6quHkesND9M8vlkOQKLXK4prf+oQxOLANuNsWL+eg=";
};
-
nativeBuildInputs = old.nativeBuildInputs ++ (with final; [automake autoconf pkg-config libtool]);
+
nativeBuildInputs =
+
old.nativeBuildInputs
+
++ (with final; [
+
automake
+
autoconf
+
pkg-config
+
libtool
+
]);
configurePhase = ''
$SHELL autogen.sh
'';
+2 -1
pkgs-set/overlays/musikcube.nix
···
-
{inputs}: final: prev: {
+
{ inputs }:
+
final: prev: {
musikcube = inputs.nixpkgs-master.legacyPackages.${final.system}.musikcube;
}
+1 -1
pkgs-set/overlays/nur.nix
···
-
{inputs}: inputs.nur.overlays.default
+
{ inputs }: inputs.nur.overlays.default
+3 -2
pkgs-set/overlays/prismlauncher.nix
···
-
{inputs}: final: prev: {
+
{ inputs }:
+
final: prev: {
prismlauncher = prev.prismlauncher.overrideAttrs (old: {
-
patches = [((toString inputs.self) + "/pkgs-set/patches/prismlauncher-offline.patch")];
+
patches = [ ((toString inputs.self) + "/pkgs-set/patches/prismlauncher-offline.patch") ];
});
}
+9 -9
pkgs-set/overlays/rofi-bluetooth.nix
···
final: prev: {
rofi-bluetooth-wayland =
-
(prev.rofi-bluetooth.override {rofi-unwrapped = final.rofi-wayland-unwrapped;})
-
.overrideAttrs (old: {
-
src = final.fetchFromGitHub {
-
owner = "nickclyde";
-
repo = "rofi-bluetooth";
-
rev = "0c07719c428984893c46f6cfe0a56660e03ccf50";
-
sha256 = "sha256-Er59/fMhcA7xCXn3abMeBlrYfDYsOBApeykR1r8XbNU=";
-
};
-
});
+
(prev.rofi-bluetooth.override { rofi-unwrapped = final.rofi-wayland-unwrapped; }).overrideAttrs
+
(old: {
+
src = final.fetchFromGitHub {
+
owner = "nickclyde";
+
repo = "rofi-bluetooth";
+
rev = "0c07719c428984893c46f6cfe0a56660e03ccf50";
+
sha256 = "sha256-Er59/fMhcA7xCXn3abMeBlrYfDYsOBApeykR1r8XbNU=";
+
};
+
});
}
+10 -2
pkgs-set/overlays/steam.nix
···
-
{inputs}: final: prev: {
+
{ inputs }:
+
final: prev: {
steam = prev.steam.override {
-
extraLibraries = pkgs: with pkgs; [mimalloc pipewire vulkan-loader wayland wayland-protocols];
+
extraLibraries =
+
pkgs: with pkgs; [
+
mimalloc
+
pipewire
+
vulkan-loader
+
wayland
+
wayland-protocols
+
];
};
}
+6 -9
pkgs-set/pkgs-to-export.nix
···
-
pkgs: (
-
pkgs.lib.getAttrs
-
[
-
"phantom"
-
"comic-mono"
-
"bitwig-studio"
-
]
-
pkgs
-
)
+
pkgs:
+
(pkgs.lib.getAttrs [
+
"phantom"
+
"comic-mono"
+
"bitwig-studio"
+
] pkgs)
+6 -5
pkgs-set/pkgs/comic-mono.nix
···
fetchurl,
runCommand,
...
-
}: let
+
}:
+
let
ttf = fetchurl {
url = "https://dtinth.github.io/comic-mono-font/ComicMono.ttf";
sha256 = "sha256-O8FCXpIqFqvw7HZ+/+TQJoQ5tMDc6YQy4H0V9drVcZY=";
};
in
-
runCommand "comic-mono" {} ''
-
mkdir -p $out/share/fonts/truetype
-
ln -s ${ttf} $out/share/fonts/truetype
-
''
+
runCommand "comic-mono" { } ''
+
mkdir -p $out/share/fonts/truetype
+
ln -s ${ttf} $out/share/fonts/truetype
+
''
+13 -12
pkgs-set/pkgs/discordo.nix
···
buildGoModule,
fetchFromGitHub,
...
-
}: let
+
}:
+
let
rev = "40e2e7e6a5533c1e0bd682cb7ccadf3e5bc5eae8";
shortRev = builtins.substring 0 8 rev;
in
-
buildGoModule {
-
pname = "discordo";
-
version = shortRev;
+
buildGoModule {
+
pname = "discordo";
+
version = shortRev;
-
src = fetchFromGitHub {
-
owner = "ayntgl";
-
repo = "discordo";
-
inherit rev;
-
sha256 = "sha256-620PwT6RVrc3orD6Ny51kyMMdcQU5bZ1gSMJDJA7H2g=";
-
};
+
src = fetchFromGitHub {
+
owner = "ayntgl";
+
repo = "discordo";
+
inherit rev;
+
sha256 = "sha256-620PwT6RVrc3orD6Ny51kyMMdcQU5bZ1gSMJDJA7H2g=";
+
};
-
vendorSha256 = "sha256-XUoKEnLy88BAeUMZ19YS/vF1TksYroayQiyds5aQ3hI=";
-
}
+
vendorSha256 = "sha256-XUoKEnLy88BAeUMZ19YS/vF1TksYroayQiyds5aQ3hI=";
+
}
+17 -2
pkgs-set/pkgs/fluidsynth-dssi.nix
···
sha256 = "sha256-DJSrdxQpjvQTzio6e3p/iSYJWu+AbydyKkeKsRQA6qc=";
};
-
nativeBuildInputs = [autoconf automake pkg-config rpm2targz libtool];
-
buildInputs = [alsa-lib dssi gtk2 libjack2 ladspaH ladspaPlugins liblo fluidsynth.dev];
+
nativeBuildInputs = [
+
autoconf
+
automake
+
pkg-config
+
rpm2targz
+
libtool
+
];
+
buildInputs = [
+
alsa-lib
+
dssi
+
gtk2
+
libjack2
+
ladspaH
+
ladspaPlugins
+
liblo
+
fluidsynth.dev
+
];
unpackPhase = ''
rpm2targz $src
+6 -1
pkgs-set/pkgs/fractal-next.nix
···
description = "Matrix group messaging app";
homepage = "https://gitlab.gnome.org/GNOME/fractal";
license = licenses.gpl3;
-
maintainers = teams.gnome.members ++ (with maintainers; [dtzWill genofire]);
+
maintainers =
+
teams.gnome.members
+
++ (with maintainers; [
+
dtzWill
+
genofire
+
]);
};
}
+1 -1
pkgs-set/pkgs/phantom.nix
···
dontWrapQtApps = true;
-
buildInputs = [libsForQt5.qt5.qtbase];
+
buildInputs = [ libsForQt5.qt5.qtbase ];
buildPhase = ''
cd src/styleplugin
+31 -9
secrets/secrets.nix
···
let
yusdacra = builtins.readFile ./yusdacra.key.pub;
wolumonde = builtins.readFile ./wolumonde.key.pub;
-
in {
-
"bernbotToken.age".publicKeys = [yusdacra wolumonde];
-
"musikquadConfig.age".publicKeys = [yusdacra wolumonde];
-
"nixGithubAccessToken.age".publicKeys = [yusdacra];
-
"websiteConfig.age".publicKeys = [yusdacra wolumonde];
-
"forgejoActRunnerToken.age".publicKeys = [yusdacra wolumonde];
-
"xrayConfig.age".publicKeys = [yusdacra wolumonde];
-
"pdsConfig.age".publicKeys = [yusdacra wolumonde];
-
"webhookAuth.age".publicKeys = [yusdacra wolumonde];
+
in
+
{
+
"bernbotToken.age".publicKeys = [
+
yusdacra
+
wolumonde
+
];
+
"musikquadConfig.age".publicKeys = [
+
yusdacra
+
wolumonde
+
];
+
"nixGithubAccessToken.age".publicKeys = [ yusdacra ];
+
"websiteConfig.age".publicKeys = [
+
yusdacra
+
wolumonde
+
];
+
"forgejoActRunnerToken.age".publicKeys = [
+
yusdacra
+
wolumonde
+
];
+
"xrayConfig.age".publicKeys = [
+
yusdacra
+
wolumonde
+
];
+
"pdsConfig.age".publicKeys = [
+
yusdacra
+
wolumonde
+
];
+
"webhookAuth.age".publicKeys = [
+
yusdacra
+
wolumonde
+
];
}
+33 -22
shells/default.nix
···
inputs,
...
}:
-
tlib.genPkgs (pkgs: let
-
mkNakedShell = pkgs.callPackage inputs.naked-shell {};
-
agenix-wrapped = pkgs.writeShellApplication {
-
name = "agenix";
-
runtimeInputs = [pkgs.agenix];
-
text = ''
-
if [ -z "''${1-}" ]; then
-
agenix
-
else
-
RULES="$FLAKE/secrets/secrets.nix" agenix -i "$FLAKE/ssh_key" "$@"
-
fi
-
'';
-
};
-
in {
-
default = mkNakedShell {
-
name = "prts";
-
packages = (with pkgs; [git nixfmt-rfc-style treefmt rage]) ++ [agenix-wrapped];
-
shellHook = ''
-
echo \"$(tput bold)welcome to PRTS, $USER$(tput sgr0)\"
-
'';
-
};
-
})
+
tlib.genPkgs (
+
pkgs:
+
let
+
mkNakedShell = pkgs.callPackage inputs.naked-shell { };
+
agenix-wrapped = pkgs.writeShellApplication {
+
name = "agenix";
+
runtimeInputs = [ pkgs.agenix ];
+
text = ''
+
if [ -z "''${1-}" ]; then
+
agenix
+
else
+
RULES="$FLAKE/secrets/secrets.nix" agenix -i "$FLAKE/ssh_key" "$@"
+
fi
+
'';
+
};
+
in
+
{
+
default = mkNakedShell {
+
name = "prts";
+
packages =
+
(with pkgs; [
+
git
+
nixfmt-rfc-style
+
treefmt
+
rage
+
])
+
++ [ agenix-wrapped ];
+
shellHook = ''
+
echo \"$(tput bold)welcome to PRTS, $USER$(tput sgr0)\"
+
'';
+
};
+
}
+
)
+1 -1
treefmt.toml
···
[formatter.nix]
# Formatter to run
-
command = "alejandra"
+
command = "nixfmt"
# Command-line arguments for the command
options = []
# Glob pattern of files to include
+65 -47
users/firewatch/default.nix
···
tlib,
config,
...
-
} @ globalAttrs: let
+
}@globalAttrs:
+
let
l = lib // builtins;
nixosConfig = globalAttrs.config;
signKeyText = builtins.readFile ../../secrets/yusdacra.key.pub;
-
in {
+
in
+
{
users.users.firewatch = {
isNormalUser = true;
createHome = true;
···
shell = pkgs.zsh;
hashedPassword = "$6$spzqhAyJfhHy$iHgLBlhjGn1l8PnbjJdWTn1GPvcjMqYNKUzdCe/7IrX6sHNgETSr/Nfpdmq9FCXLhrAfwHOd/q/8SvfeIeNX4/";
};
-
environment.shells = with pkgs; [bashInteractive zsh];
+
environment.shells = with pkgs; [
+
bashInteractive
+
zsh
+
];
programs = {
# cuz nixos complains
zsh.enable = true;
};
-
home-manager.users.firewatch = {
-
config,
-
pkgs,
-
inputs,
-
secrets,
-
...
-
}: let
-
personal = import ../../personal.nix;
-
name = personal.name;
-
email = personal.emails.primary;
-
in {
-
imports = let
-
modulesToEnable = l.flatten [
-
["zoxide" "zsh" "fzf" "starship" "direnv"]
-
# dev stuff
-
["helix" "git" "ssh"]
-
];
+
home-manager.users.firewatch =
+
{
+
config,
+
pkgs,
+
inputs,
+
secrets,
+
...
+
}:
+
let
+
personal = import ../../personal.nix;
+
name = personal.name;
+
email = personal.emails.primary;
in
-
l.flatten [
-
../../modules/persist/null.nix
-
(tlib.prefixStrings "${inputs.self}/users/modules/" modulesToEnable)
-
];
+
{
+
imports =
+
let
+
modulesToEnable = l.flatten [
+
[
+
"zoxide"
+
"zsh"
+
"fzf"
+
"starship"
+
"direnv"
+
]
+
# dev stuff
+
[
+
"helix"
+
"git"
+
"ssh"
+
]
+
];
+
in
+
l.flatten [
+
../../modules/persist/null.nix
+
(tlib.prefixStrings "${inputs.self}/users/modules/" modulesToEnable)
+
];
-
settings.enable = false;
+
settings.enable = false;
-
home = {
-
homeDirectory = nixosConfig.users.users.firewatch.home;
-
packages = with pkgs; [
-
# Programs
-
nix-output-monitor
-
inputs.nh.packages.${pkgs.system}.default
-
];
-
file.".ssh/authorized_keys".text = ''
-
${signKeyText}
-
'';
-
};
+
home = {
+
homeDirectory = nixosConfig.users.users.firewatch.home;
+
packages = with pkgs; [
+
# Programs
+
nix-output-monitor
+
inputs.nh.packages.${pkgs.system}.default
+
];
+
file.".ssh/authorized_keys".text = ''
+
${signKeyText}
+
'';
+
};
-
programs = {
-
command-not-found.enable =
-
nixosConfig.programs.command-not-found.enable;
-
git = {
-
userName = name;
-
userEmail = email;
-
extraConfig = {
-
gpg.format = "ssh";
-
commit.gpgsign = true;
-
user.signingkey = signKeyText;
+
programs = {
+
command-not-found.enable = nixosConfig.programs.command-not-found.enable;
+
git = {
+
userName = name;
+
userEmail = email;
+
extraConfig = {
+
gpg.format = "ssh";
+
commit.gpgsign = true;
+
user.signingkey = signKeyText;
+
};
};
};
};
-
};
}
+3 -2
users/modules/arrpc/default.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
systemd.user.services.arrpc = {
Install = {
-
WantedBy = ["default.target"];
+
WantedBy = [ "default.target" ];
};
Unit = {
Description = "arrpc";
+2 -1
users/modules/chromium/default.nix
···
-
{config, ...}: {
+
{ config, ... }:
+
{
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [
".config/chromium"
".local/share/applications"
+2 -1
users/modules/code/default.nix
···
pkgs,
inputs,
...
-
}: {
+
}:
+
{
# stylix.targets.vscode.enable = false;
programs.vscode = {
enable = true;
+29 -26
users/modules/discord/default.nix
···
pkgs,
lib,
...
-
}: {
+
}:
+
{
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [
".config/ArmCord"
];
-
home.packages = let
-
flags = [
-
# "--flag-switches-begin"
-
# "--enable-features=UseOzonePlatform,WebRTCPipeWireCapturer"
-
# "--flag-switches-end"
-
# "--ozone-platform=wayland"
-
# "--enable-webrtc-pipewire-capturer"
-
# "--disable-gpu-memory-buffer-video-frames"
-
# "--enable-accelerated-mjpeg-decode"
-
# "--enable-accelerated-video"
-
# "--enable-gpu-rasterization"
-
# "--enable-native-gpu-memory-buffers"
-
# "--enable-zero-copy"
-
# "--ignore-gpu-blocklist"
-
];
-
pkg =
-
(pkgs.armcord.override {
-
nss = pkgs.nss_latest;
-
})
-
.overrideAttrs (old: {
-
# preInstall = ''
-
# gappsWrapperArgs+=("--add-flags" "${lib.concatStringsSep " " flags}")
-
# '';
-
});
-
in [pkg];
+
home.packages =
+
let
+
flags = [
+
# "--flag-switches-begin"
+
# "--enable-features=UseOzonePlatform,WebRTCPipeWireCapturer"
+
# "--flag-switches-end"
+
# "--ozone-platform=wayland"
+
# "--enable-webrtc-pipewire-capturer"
+
# "--disable-gpu-memory-buffer-video-frames"
+
# "--enable-accelerated-mjpeg-decode"
+
# "--enable-accelerated-video"
+
# "--enable-gpu-rasterization"
+
# "--enable-native-gpu-memory-buffers"
+
# "--enable-zero-copy"
+
# "--ignore-gpu-blocklist"
+
];
+
pkg =
+
(pkgs.armcord.override {
+
nss = pkgs.nss_latest;
+
}).overrideAttrs
+
(old: {
+
# preInstall = ''
+
# gappsWrapperArgs+=("--add-flags" "${lib.concatStringsSep " " flags}")
+
# '';
+
});
+
in
+
[ pkg ];
}
+3 -2
users/modules/discordrp-mpris/default.nix
···
inputs,
pkgs,
...
-
}: {
+
}:
+
{
systemd.user.services.discordrp-mpris = {
Install = {
-
WantedBy = ["default.target"];
+
WantedBy = [ "default.target" ];
};
Unit = {
Description = "discordrp-mpris";
+5 -2
users/modules/dunst/default.nix
···
-
{config, ...}: {
+
{ config, ... }:
+
{
# notification daemon
services.dunst = {
enable = true;
···
word_wrap = "yes";
};
-
fullscreen_delay_everything = {fullscreen = "delay";};
+
fullscreen_delay_everything = {
+
fullscreen = "delay";
+
};
};
};
}
+8 -6
users/modules/firefox/default.nix
···
pkgs,
config,
...
-
}: {
+
}:
+
{
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [
".mozilla"
".floorp"
];
-
home.packages = [(pkgs.lib.hiPrio pkgs.floorp)];
+
home.packages = [ (pkgs.lib.hiPrio pkgs.floorp) ];
programs.firefox = {
enable = true;
package = pkgs.firefox.override {
···
id = 1;
isDefault = true;
name = "personal";
-
extensions = with pkgs.nur.repos.rycee.firefox-addons; let
-
myExtensions =
-
pkgs.callPackage ./extensions.nix {inherit buildFirefoxXpiAddon;};
-
in
+
extensions =
+
with pkgs.nur.repos.rycee.firefox-addons;
+
let
+
myExtensions = pkgs.callPackage ./extensions.nix { inherit buildFirefoxXpiAddon; };
+
in
[
ublock-origin
darkreader
+3 -2
users/modules/firefox/extensions.nix
···
fetchurl,
lib,
stdenv,
-
}: {
+
}:
+
{
"better-clean-twitter" = buildFirefoxXpiAddon {
pname = "better-clean-twitter";
version = "1.3.2";
···
meta = with lib; {
description = "Firefox theme based on <a href=\"https://prod.outgoing.prod.webservices.mozgcp.net/v1/110954a3f2718cf03892676379416caed51099b639f643aaf12989b7e698f073/https%3A//github.com/catppuccin/catppuccin\" rel=\"nofollow\">https://github.com/catppuccin/catppuccin</a>";
license = licenses.cc-by-30;
-
mozPermissions = [];
+
mozPermissions = [ ];
platforms = platforms.all;
};
};
+2 -1
users/modules/fluxbox/default.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
xsession.enable = true;
xsession.windowManager.fluxbox = {
enable = true;
+2 -1
users/modules/foot/default.nix
···
lib,
pkgs,
...
-
}: {
+
}:
+
{
settings.terminal.name = "foot";
settings.terminal.binary = "${pkgs.foot}/bin/foot";
programs.foot = {
+2 -1
users/modules/fzf/default.nix
···
-
{config, ...}: {
+
{ config, ... }:
+
{
programs.fzf.enable = true;
# home.sessionVariables = {
# FZF_DEFAULT_OPTS = "--color=spinner:#F8BD96,hl:#F28FAD --color=fg:#D9E0EE,header:#F28FAD,info:#DDB6F2,pointer:#F8BD96 --color=marker:#F8BD96,fg+:#F2CDCD,prompt:#DDB6F2,hl+:#F28FAD";
+2 -1
users/modules/git/default.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
programs.git = {
enable = true;
extraConfig = {
+3 -2
users/modules/godot/default.nix
···
-
{pkgs, ...}: {
-
home.packages = with pkgs; [godot_4];
+
{ pkgs, ... }:
+
{
+
home.packages = with pkgs; [ godot_4 ];
}
+25 -6
users/modules/helix/default.nix
···
inputs,
pkgs,
...
-
}: {
+
}:
+
{
stylix.targets.helix.enable = false;
programs.helix = {
enable = true;
languages.language = [
{
name = "dockerfile";
-
roots = ["Dockerfile" "Containerfile"];
-
file-types = ["Dockerfile" "Containerfile" "dockerfile" "containerfile"];
+
roots = [
+
"Dockerfile"
+
"Containerfile"
+
];
+
file-types = [
+
"Dockerfile"
+
"Containerfile"
+
"dockerfile"
+
"containerfile"
+
];
}
];
settings = {
···
"<" = ">";
};
statusline = {
-
left = ["mode" "spinner"];
-
center = ["file-name" "file-encoding" "version-control"];
-
right = ["diagnostics" "selections"];
+
left = [
+
"mode"
+
"spinner"
+
];
+
center = [
+
"file-name"
+
"file-encoding"
+
"version-control"
+
];
+
right = [
+
"diagnostics"
+
"selections"
+
];
};
};
};
+18 -11
users/modules/hyprland/config.nix
···
config,
pkgs,
...
-
}: let
-
run-as-service = slice:
+
}:
+
let
+
run-as-service =
+
slice:
pkgs.writeShellScript "as-systemd-transient" ''
exec ${pkgs.systemd}/bin/systemd-run \
--slice=app-${slice}.slice \
···
launcher = "rofi";
launcherCmd = "${launcher} -show drun";
term = config.settings.terminal.name;
-
in {
+
in
+
{
wayland.windowManager.hyprland.extraConfig = ''
# should be configured per-profile
monitor=eDP-1,preferred,0x0,1.6
···
bind=SUPERSHIFT,braceright,focusmonitor,r
# workspaces
-
${builtins.concatStringsSep "\n" (builtins.genList (
-
x: let
-
ws = let
-
c = (x + 1) / 10;
-
in
+
${builtins.concatStringsSep "\n" (
+
builtins.genList (
+
x:
+
let
+
ws =
+
let
+
c = (x + 1) / 10;
+
in
builtins.toString (x + 1 - (c * 10));
-
in ''
+
in
+
''
bind=SUPER,${ws},workspace,${toString (x + 1)}
bind=SHIFTSUPER,${ws},movetoworkspacesilent,${toString (x + 1)}
''
-
)
-
10)}
+
) 10
+
)}
# screenshot
bind=,Print,exec,grimblast --notify copysave area
+2 -1
users/modules/hyprland/default.nix
···
pkgs,
inputs,
...
-
}: {
+
}:
+
{
imports = [
../wayland
../swaylock
+7 -3
users/modules/hyprland/swayidle.nix
···
pkgs,
lib,
...
-
}: {
-
home.packages = with pkgs; [wlopm swayidle];
+
}:
+
{
+
home.packages = with pkgs; [
+
wlopm
+
swayidle
+
];
services.swayidle = {
enable = true;
events = [
···
}
];
};
-
systemd.user.services.swayidle.Install.WantedBy = lib.mkForce ["hyprland-session.target"];
+
systemd.user.services.swayidle.Install.WantedBy = lib.mkForce [ "hyprland-session.target" ];
}
+6 -3
users/modules/lollypop/default.nix
···
config,
pkgs,
...
-
}: {
-
home.packages = [pkgs.lollypop];
-
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [".local/share/lollypop"];
+
}:
+
{
+
home.packages = [ pkgs.lollypop ];
+
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [
+
".local/share/lollypop"
+
];
}
+2 -1
users/modules/mako/default.nix
···
-
{...}: {
+
{ ... }:
+
{
programs.mako = {
enable = true;
anchor = "top-center";
+9 -5
users/modules/musikcube/default.nix
···
pkgs,
lib,
...
-
}: let
+
}:
+
let
cfg = config.programs.musikcube;
-
in {
+
in
+
{
options = {
programs.musikcube = {
enable = lib.mkEnableOption "whether to enable musikcube";
···
default = pkgs.musikcube;
};
settings = lib.mkOption {
-
type = (pkgs.formats.json {}).type;
+
type = (pkgs.formats.json { }).type;
default = builtins.fromJSON (builtins.readFile ./default-config.json);
};
};
};
config = lib.mkIf cfg.enable {
-
home.packages = [cfg.package];
-
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [".config/musikcube"];
+
home.packages = [ cfg.package ];
+
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [
+
".config/musikcube"
+
];
xdg.configFile."musikcube/settings.json".text = builtins.toJSON cfg.settings;
};
}
+8 -5
users/modules/musikcubed/default.nix
···
lib,
pkgs,
...
-
}: let
+
}:
+
let
cfg = config.services.musikcubed;
-
in {
+
in
+
{
options = {
services.musikcubed = {
enable = lib.mkEnableOption "whether to enable musikcubed";
···
default = pkgs.musikcube;
};
settings = lib.mkOption {
-
type = (pkgs.formats.json {}).type;
+
type = (pkgs.formats.json { }).type;
default = builtins.fromJSON (builtins.readFile ./default-config.json);
};
};
···
config = lib.mkIf cfg.enable {
systemd.user.services.musikcubed = {
Install = {
-
WantedBy = ["default.target"];
+
WantedBy = [ "default.target" ];
};
Unit = {
Description = "musikcubed";
···
RestartSec = 5;
};
};
-
xdg.configFile."musikcube/plugin_musikcubeserver(wss,http).json".text = builtins.toJSON cfg.settings;
+
xdg.configFile."musikcube/plugin_musikcubeserver(wss,http).json".text =
+
builtins.toJSON cfg.settings;
};
}
+3 -2
users/modules/newsflash/default.nix
···
config,
pkgs,
...
-
}: {
-
home.packages = [pkgs.newsflash];
+
}:
+
{
+
home.packages = [ pkgs.newsflash ];
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [
".local/share/news-flash"
".config/news-flash"
+6 -3
users/modules/obsidian/default.nix
···
config,
lib,
...
-
}: {
-
home.packages = [pkgs.obsidian];
-
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [".config/obsidian"];
+
}:
+
{
+
home.packages = [ pkgs.obsidian ];
+
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [
+
".config/obsidian"
+
];
}
+3 -2
users/modules/premid/default.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
systemd.user.services.premid = {
Install = {
-
WantedBy = ["default.target"];
+
WantedBy = [ "default.target" ];
};
Unit = {
Description = "premid";
+8 -3
users/modules/psd/default.nix
···
-
username: {pkgs, ...}: {
+
username:
+
{ pkgs, ... }:
+
{
services.psd.enable = true;
security.sudo.extraRules = [
{
-
users = [username];
+
users = [ username ];
commands = [
{
command = "${pkgs.profile-sync-daemon}/bin/psd-overlay-helper";
-
options = ["SETENV" "NOPASSWD"];
+
options = [
+
"SETENV"
+
"NOPASSWD"
+
];
}
];
}
+3 -2
users/modules/ripcord/default.nix
···
config,
pkgs,
...
-
}: {
-
home.packages = [pkgs.ripcord];
+
}:
+
{
+
home.packages = [ pkgs.ripcord ];
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [
".local/share/Ripcord"
];
+6 -4
users/modules/rofi-nm/default.nix
···
pkgs,
lib,
...
-
}: let
+
}:
+
let
rofi-nm = pkgs.fetchurl {
url = "https://raw.githubusercontent.com/P3rf/rofi-network-manager/1daa69406c9b6539a4744eafb0d5bb8afdc80e9b/rofi-network-manager.sh";
hash = "sha256:1nlnjmk5b743j5826z2nzfvjwk0fmbf7gk38darby93kdr3nv5zx";
···
package = pkgs.writeShellScriptBin "rofi-nm" ''
${config.home.homeDirectory}/.config/rofi-nm/rofi-nm.sh
'';
-
in {
+
in
+
{
options = {
programs.rofi-nm.package = lib.mkOption {
type = lib.types.package;
···
config = {
programs.rofi-nm.package = package;
-
home.packages = [package];
+
home.packages = [ package ];
xdg.configFile = {
"rofi-nm/rofi-nm.sh" = {
-
source = pkgs.runCommandLocal "rofi-nm" {} ''
+
source = pkgs.runCommandLocal "rofi-nm" { } ''
cp --no-preserve=mode,ownership ${rofi-nm} rofi-nm.sh
substituteInPlace rofi-nm.sh \
--replace "#!/bin/bash" "#!${pkgs.stdenv.shell}" \
+2 -1
users/modules/rofi/default.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
programs.rofi = {
enable = true;
package = pkgs.rofi-wayland;
+3 -2
users/modules/s3s/default.nix
···
config,
inputs,
...
-
}: {
-
imports = [inputs.s3s.homeManagerModule];
+
}:
+
{
+
imports = [ inputs.s3s.homeManagerModule ];
services.s3s.enable = true;
}
+4 -2
users/modules/settings/default.nix
···
config,
lib,
...
-
}: let
+
}:
+
let
l = lib // builtins;
t = l.types;
cfg = config.settings;
-
in {
+
in
+
{
options = {
settings.enable = l.mkOption {
type = t.bool;
+5 -3
users/modules/smos/default.nix
···
inputs,
secrets,
...
-
}: let
+
}:
+
let
smosDir = "${config.home.homeDirectory}/smos";
-
in {
-
imports = ["${inputs.smos}/nix/home-manager-module.nix"];
+
in
+
{
+
imports = [ "${inputs.smos}/nix/home-manager-module.nix" ];
programs.smos = {
enable = true;
notify.enable = true;
+3 -2
users/modules/spotify/default.nix
···
config,
pkgs,
...
-
}: {
+
}:
+
{
services.spotifyd = {
enable = true;
settings = {
device_name = "nix";
};
};
-
home.packages = [pkgs.spotify-tui];
+
home.packages = [ pkgs.spotify-tui ];
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories = [
".config/spotify-tui"
];
+2 -1
users/modules/ssh/default.nix
···
-
{nixosConfig, ...}: {
+
{ nixosConfig, ... }:
+
{
programs.ssh = {
enable = true;
compression = true;
+2 -1
users/modules/starship/default.nix
···
-
{...}: {
+
{ ... }:
+
{
programs.starship = {
enable = true;
settings = {
+101 -95
users/modules/sway/default.nix
···
lib,
tlib,
...
-
}: {
+
}:
+
{
imports = [
../wayland
../swaylock
···
# ./swayidle.nix
];
wayland.windowManager = {
-
sway = let
-
mkRofiCmd = args: "${config.programs.rofi.package}/bin/rofi ${lib.concatStringsSep " " args} | ${pkgs.sway}/bin/swaymsg --";
-
inherit (tlib) pkgBin;
-
in {
-
enable = true;
-
extraSessionCommands = ''
-
export QT_QPA_PLATFORM=wayland
-
'';
-
wrapperFeatures.gtk = true;
-
extraConfig = ''
-
exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway
-
exec xprop -root -f _XWAYLAND_GLOBAL_OUTPUT_SCALE 32c -set _XWAYLAND_GLOBAL_OUTPUT_SCALE 2
-
'';
-
config = {
-
bars = [];
-
gaps.smartBorders = "on";
-
menu = mkRofiCmd [
-
"-show"
-
"drun"
-
];
-
modifier = "Mod4";
-
terminal = config.settings.terminal.binary;
-
keybindings = let
-
mod = config.wayland.windowManager.sway.config.modifier;
+
sway =
+
let
+
mkRofiCmd =
+
args:
+
"${config.programs.rofi.package}/bin/rofi ${lib.concatStringsSep " " args} | ${pkgs.sway}/bin/swaymsg --";
+
inherit (tlib) pkgBin;
+
in
+
{
+
enable = true;
+
extraSessionCommands = ''
+
export QT_QPA_PLATFORM=wayland
+
'';
+
wrapperFeatures.gtk = true;
+
extraConfig = ''
+
exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway
+
exec xprop -root -f _XWAYLAND_GLOBAL_OUTPUT_SCALE 32c -set _XWAYLAND_GLOBAL_OUTPUT_SCALE 2
+
'';
+
config = {
+
bars = [ ];
+
gaps.smartBorders = "on";
+
menu = mkRofiCmd [
+
"-show"
+
"drun"
+
];
+
modifier = "Mod4";
+
terminal = config.settings.terminal.binary;
+
keybindings =
+
let
+
mod = config.wayland.windowManager.sway.config.modifier;
-
cat = pkgs.coreutils + "/bin/cat";
-
grim = pkgBin pkgs.grim;
-
slurp = pkgBin pkgs.slurp;
-
pactl = pkgs.pulseaudio + "/bin/pactl";
-
playerctl = pkgBin pkgs.playerctl;
-
wf-recorder = pkgBin pkgs.wf-recorder;
-
wl-copy = pkgs.wl-clipboard + "/bin/wl-copy";
-
wlogout = pkgBin pkgs.wlogout;
-
light = pkgBin pkgs.light;
+
cat = pkgs.coreutils + "/bin/cat";
+
grim = pkgBin pkgs.grim;
+
slurp = pkgBin pkgs.slurp;
+
pactl = pkgs.pulseaudio + "/bin/pactl";
+
playerctl = pkgBin pkgs.playerctl;
+
wf-recorder = pkgBin pkgs.wf-recorder;
+
wl-copy = pkgs.wl-clipboard + "/bin/wl-copy";
+
wlogout = pkgBin pkgs.wlogout;
+
light = pkgBin pkgs.light;
-
shotFile = config.home.homeDirectory + "/shots/shot_$(date '+%Y_%m_%d_%H_%M')";
-
shotDir = config.home.homeDirectory + "/shots";
-
in
-
lib.mkOptionDefault
-
{
-
"${mod}+Escape" = "exec ${wlogout} -p layer-shell";
-
"${mod}+q" = "kill";
-
"${mod}+Shift+e" = "exit";
-
"${mod}+Shift+r" = "reload";
-
# Screenshot and copy it to clipboard
-
"Mod1+s" = ''
-
exec export SFILE="${shotFile}.png" && mkdir -p ${shotDir} && ${grim} "$SFILE" && ${cat} "$SFILE" | ${wl-copy} -t image/png
-
'';
-
# Save selected area as a picture and copy it to clipboard
-
"Mod1+Shift+s" = ''
-
exec export SFILE="${shotFile}.png" && mkdir -p ${shotDir} && ${grim} -g "$(${slurp})" "$SFILE" && ${cat} "$SFILE" | ${wl-copy} -t image/png
-
'';
-
# Record screen
-
"Mod1+r" = ''exec mkdir -p ${shotDir} && ${wf-recorder} -x yuv420p -f "${shotFile}.mp4"'';
-
# Record an area
-
"Mod1+Shift+r" = ''exec mkdir -p ${shotDir} && ${wf-recorder} -x yuv420p -g "$(${slurp})" -f "${shotFile}.mp4"'';
-
# Stop recording
-
"Mod1+c" = "exec pkill -INT wf-recorder";
-
"XF86AudioRaiseVolume" = "exec ${pactl} set-sink-volume 0 +5%";
-
"XF86AudioLowerVolume" = "exec ${pactl} set-sink-volume 0 -5%";
-
"XF86AudioMute" = "exec ${pactl} set-sink-mute 0 toggle";
-
"XF86AudioPlay" = "exec ${playerctl} play-pause";
-
"XF86AudioPrev" = "exec ${playerctl} previous";
-
"XF86AudioNext" = "exec ${playerctl} next";
-
"XF86AudioStop" = "exec ${playerctl} stop";
-
"XF86MonBrightnessUp" = "exec ${light} -T 1.4";
-
"XF86MonBrightnessDown" = "exec ${light} -T 0.72";
-
};
-
input = {
-
"13364:832:Keychron_Keychron_V4_Keyboard" = {
-
xkb_layout = nixosConfig.services.xserver.layout;
-
};
-
"1:1:AT_Translated_Set_2_keyboard" = {
-
xkb_layout = "tr";
-
};
-
"type:pointer" = {
-
accel_profile = "flat";
-
};
-
"type:touchpad" = {
-
accel_profile = "adaptive";
-
tap = "enabled";
-
scroll_method = "two_finger";
-
dwt = "enabled";
-
events = "disabled_on_external_mouse";
-
};
-
};
-
output = {
-
"*" = {
-
bg = "${config.stylix.image} fill";
-
};
-
"eDP-1" = {
-
scale = "2";
-
adaptive_sync = "on";
+
shotFile = config.home.homeDirectory + "/shots/shot_$(date '+%Y_%m_%d_%H_%M')";
+
shotDir = config.home.homeDirectory + "/shots";
+
in
+
lib.mkOptionDefault {
+
"${mod}+Escape" = "exec ${wlogout} -p layer-shell";
+
"${mod}+q" = "kill";
+
"${mod}+Shift+e" = "exit";
+
"${mod}+Shift+r" = "reload";
+
# Screenshot and copy it to clipboard
+
"Mod1+s" = ''
+
exec export SFILE="${shotFile}.png" && mkdir -p ${shotDir} && ${grim} "$SFILE" && ${cat} "$SFILE" | ${wl-copy} -t image/png
+
'';
+
# Save selected area as a picture and copy it to clipboard
+
"Mod1+Shift+s" = ''
+
exec export SFILE="${shotFile}.png" && mkdir -p ${shotDir} && ${grim} -g "$(${slurp})" "$SFILE" && ${cat} "$SFILE" | ${wl-copy} -t image/png
+
'';
+
# Record screen
+
"Mod1+r" = ''exec mkdir -p ${shotDir} && ${wf-recorder} -x yuv420p -f "${shotFile}.mp4"'';
+
# Record an area
+
"Mod1+Shift+r" =
+
''exec mkdir -p ${shotDir} && ${wf-recorder} -x yuv420p -g "$(${slurp})" -f "${shotFile}.mp4"'';
+
# Stop recording
+
"Mod1+c" = "exec pkill -INT wf-recorder";
+
"XF86AudioRaiseVolume" = "exec ${pactl} set-sink-volume 0 +5%";
+
"XF86AudioLowerVolume" = "exec ${pactl} set-sink-volume 0 -5%";
+
"XF86AudioMute" = "exec ${pactl} set-sink-mute 0 toggle";
+
"XF86AudioPlay" = "exec ${playerctl} play-pause";
+
"XF86AudioPrev" = "exec ${playerctl} previous";
+
"XF86AudioNext" = "exec ${playerctl} next";
+
"XF86AudioStop" = "exec ${playerctl} stop";
+
"XF86MonBrightnessUp" = "exec ${light} -T 1.4";
+
"XF86MonBrightnessDown" = "exec ${light} -T 0.72";
+
};
+
input = {
+
"13364:832:Keychron_Keychron_V4_Keyboard" = {
+
xkb_layout = nixosConfig.services.xserver.layout;
+
};
+
"1:1:AT_Translated_Set_2_keyboard" = {
+
xkb_layout = "tr";
+
};
+
"type:pointer" = {
+
accel_profile = "flat";
+
};
+
"type:touchpad" = {
+
accel_profile = "adaptive";
+
tap = "enabled";
+
scroll_method = "two_finger";
+
dwt = "enabled";
+
events = "disabled_on_external_mouse";
+
};
};
-
"HDMI-A-1" = {
-
mode = "1920x1080@74.973Hz";
+
output = {
+
"*" = {
+
bg = "${config.stylix.image} fill";
+
};
+
"eDP-1" = {
+
scale = "2";
+
adaptive_sync = "on";
+
};
+
"HDMI-A-1" = {
+
mode = "1920x1080@74.973Hz";
+
};
};
};
};
-
};
};
}
+2 -1
users/modules/swaylock/default.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
programs.swaylock = {
package = pkgs.swaylock-effects;
settings = {
+2 -1
users/modules/urxvt/default.nix
···
-
{...}: {
+
{ ... }:
+
{
programs.urxvt = {
enable = true;
keybindings = {
+3 -2
users/modules/vesktop/default.nix
···
-
{pkgs, ...}: {
-
home.packages = [pkgs.vesktop];
+
{ pkgs, ... }:
+
{
+
home.packages = [ pkgs.vesktop ];
}
+2 -1
users/modules/wayland/default.nix
···
-
{pkgs, ...}: {
+
{ pkgs, ... }:
+
{
home.packages = with pkgs; [
wl-clipboard
];
+3 -2
users/modules/wezterm/default.nix
···
pkgs,
config,
...
-
}: {
+
}:
+
{
settings.terminal.name = "wezterm";
-
home.packages = [pkgs.wezterm];
+
home.packages = [ pkgs.wezterm ];
xdg.enable = true;
xdg.configFile = {
"wezterm/wezterm.lua".text = ''
+4 -2
users/modules/wlsunset/default.nix
···
-
{inputs, ...}: let
+
{ inputs, ... }:
+
let
geo = import "${inputs.self}/locale/geo.nix";
-
in {
+
in
+
{
services.wlsunset = {
enable = true;
latitude = geo.lat;
+4 -1
users/modules/wtf/default.nix
···
-
{pkgs, ...}: {home.packages = [pkgs.wtf];}
+
{ pkgs, ... }:
+
{
+
home.packages = [ pkgs.wtf ];
+
}
+3 -2
users/modules/zoxide/default.nix
···
config,
lib,
...
-
}: {
-
home.packages = [pkgs.zoxide];
+
}:
+
{
+
home.packages = [ pkgs.zoxide ];
home.persistence."${config.system.persistDir}${config.home.homeDirectory}".directories =
lib.singleton ".local/share/zoxide";
programs.zsh.initExtra = ''
+16 -8
users/modules/zsh/default.nix
···
lib,
pkgs,
...
-
}: let
+
}:
+
let
pkgBin = tlib.pkgBin;
-
in {
+
in
+
{
programs.zsh = {
enable = true;
autocd = true;
···
# configure history
history = {
extended = true;
-
ignorePatterns = ["rm *" "mv *" "l" "ls" "ll" "g s" "git status"];
+
ignorePatterns = [
+
"rm *"
+
"mv *"
+
"l"
+
"ls"
+
"ll"
+
"g s"
+
"git status"
+
];
save = 1000000;
size = 1000000;
};
···
history.path = "${config.home.homeDirectory}/.local/share/zsh/history";
# extra stuff for fixing gpg-agent ssh and some random commands
initExtra = ''
-
${
-
lib.optionalString
-
(config.programs.ssh.enable && config.services.gpg-agent.enable)
-
"export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)"
-
}
+
${lib.optionalString (
+
config.programs.ssh.enable && config.services.gpg-agent.enable
+
) "export SSH_AUTH_SOCK=$(gpgconf --list-dirs agent-ssh-socket)"}
function tomp4 () {
${pkgBin pkgs.ffmpeg} -i $1 -c:v libx264 -preset slow -crf 30 -c:a aac -b:a 128k "$1.mp4"
+222 -186
users/patriot/default.nix
···
tlib,
config,
...
-
} @ globalAttrs: let
+
}@globalAttrs:
+
let
l = lib // builtins;
nixosConfig = globalAttrs.config;
-
in {
-
imports = [./stylix.nix];
+
in
+
{
+
imports = [ ./stylix.nix ];
users.users.patriot = {
isNormalUser = true;
···
"nix-build-key-access"
(l.optional nixosConfig.networking.networkmanager.enable "networkmanager")
(l.optional nixosConfig.virtualisation.docker.enable "docker")
-
(l.optionals nixosConfig.virtualisation.libvirtd.enable ["libvirtd" "kvm"])
+
(l.optionals nixosConfig.virtualisation.libvirtd.enable [
+
"libvirtd"
+
"kvm"
+
])
];
shell = pkgs.zsh;
hashedPassword = "$6$spzqhAyJfhHy$iHgLBlhjGn1l8PnbjJdWTn1GPvcjMqYNKUzdCe/7IrX6sHNgETSr/Nfpdmq9FCXLhrAfwHOd/q/8SvfeIeNX4/";
···
"/home/patriot/.config/unity3d"
"/home/patriot/.config/HKModInstaller"
];
-
systemPackages = with pkgs; [qt5.qtwayland];
-
shells = with pkgs; [bashInteractive zsh];
+
systemPackages = with pkgs; [ qt5.qtwayland ];
+
shells = with pkgs; [
+
bashInteractive
+
zsh
+
];
};
xdg.portal = {
enable = true;
···
# gnome stuffs
seahorse.enable = true;
dconf.enable = true;
-
weylus.users = ["patriot"];
+
weylus.users = [ "patriot" ];
java = {
enable = false;
package = pkgs.jre8;
···
NetworkManager-wait-online.enable = false;
};
};
-
home-manager.users.patriot = {
-
config,
-
pkgs,
-
inputs,
-
secrets,
-
...
-
}: let
-
personal = import ../../personal.nix;
-
name = personal.name;
-
email = personal.emails.primary;
-
in {
-
imports = let
-
modulesToEnable = l.flatten [
-
# wm
-
# ["hyprland" "foot"]
-
["sway" "wayland" "foot"]
-
# ["fluxbox" "urxvt"]
-
# desktop stuff
-
# ["wayland" "foot"]
-
["obsidian" "firefox" "vesktop"]
-
# cli stuff
-
["zoxide" "zsh" "fzf" "starship" "direnv"]
-
# dev stuff
-
["helix" "git" "ssh"]
-
# ["godot"]
-
["musikcube" "musikcubed"]
-
["arrpc"]
-
["s3s"]
-
];
+
home-manager.users.patriot =
+
{
+
config,
+
pkgs,
+
inputs,
+
secrets,
+
...
+
}:
+
let
+
personal = import ../../personal.nix;
+
name = personal.name;
+
email = personal.emails.primary;
in
-
l.flatten [
-
../../modules/persist
-
inputs.nixos-persistence.nixosModules.home-manager.impermanence
-
(tlib.prefixStrings "${inputs.self}/users/modules/" modulesToEnable)
-
];
-
-
system.persistDir = nixosConfig.system.persistDir;
-
-
home.persistence."${config.system.persistDir}${config.home.homeDirectory}" = let
-
mkPaths = pfx: paths: tlib.prefixStrings "${pfx}/" (l.flatten paths);
-
in {
-
directories =
+
{
+
imports =
+
let
+
modulesToEnable = l.flatten [
+
# wm
+
# ["hyprland" "foot"]
+
[
+
"sway"
+
"wayland"
+
"foot"
+
]
+
# ["fluxbox" "urxvt"]
+
# desktop stuff
+
# ["wayland" "foot"]
+
[
+
"obsidian"
+
"firefox"
+
"vesktop"
+
]
+
# cli stuff
+
[
+
"zoxide"
+
"zsh"
+
"fzf"
+
"starship"
+
"direnv"
+
]
+
# dev stuff
+
[
+
"helix"
+
"git"
+
"ssh"
+
]
+
# ["godot"]
+
[
+
"musikcube"
+
"musikcubed"
+
]
+
[ "arrpc" ]
+
[ "s3s" ]
+
];
+
in
l.flatten [
-
"Downloads"
-
".wine"
-
# ssh / gpg / keys
-
".ssh"
-
".gnupg"
-
"keys"
-
# caches / history stuff
-
".directory_history"
-
".cache"
-
"Bitwig Studio"
-
".BitwigStudio"
-
".vst"
-
]
-
++ mkPaths ".local/share" [
-
"bottles"
-
"direnv"
-
"zsh"
-
"keyrings"
-
"yuzu"
-
# "lutris"
-
# "Terraria"
-
"PrismLauncher"
-
]
-
++ mkPaths ".config" [
-
# "lutris"
-
"dconf"
-
"retroarch"
-
"yuzu"
-
"blender"
+
../../modules/persist
+
inputs.nixos-persistence.nixosModules.home-manager.impermanence
+
(tlib.prefixStrings "${inputs.self}/users/modules/" modulesToEnable)
];
-
files = l.flatten [
-
".config/gnome-initial-setup-done"
-
(lib.removePrefix "~/" config.programs.ssh.userKnownHostsFile)
-
];
-
allowOther = true;
-
};
-
fonts.fontconfig.enable = l.mkForce true;
+
system.persistDir = nixosConfig.system.persistDir;
-
settings.iconTheme = {
-
name = "Yaru-dark";
-
package = pkgs.yaru-theme;
-
};
+
home.persistence."${config.system.persistDir}${config.home.homeDirectory}" =
+
let
+
mkPaths = pfx: paths: tlib.prefixStrings "${pfx}/" (l.flatten paths);
+
in
+
{
+
directories =
+
l.flatten [
+
"Downloads"
+
".wine"
+
# ssh / gpg / keys
+
".ssh"
+
".gnupg"
+
"keys"
+
# caches / history stuff
+
".directory_history"
+
".cache"
+
"Bitwig Studio"
+
".BitwigStudio"
+
".vst"
+
]
+
++ mkPaths ".local/share" [
+
"bottles"
+
"direnv"
+
"zsh"
+
"keyrings"
+
"yuzu"
+
# "lutris"
+
# "Terraria"
+
"PrismLauncher"
+
]
+
++ mkPaths ".config" [
+
# "lutris"
+
"dconf"
+
"retroarch"
+
"yuzu"
+
"blender"
+
];
+
files = l.flatten [
+
".config/gnome-initial-setup-done"
+
(lib.removePrefix "~/" config.programs.ssh.userKnownHostsFile)
+
];
+
allowOther = true;
+
};
-
home.pointerCursor = {
-
package = pkgs.bibata-cursors;
-
name = "Bibata-Modern-Classic";
-
size = 24;
+
fonts.fontconfig.enable = l.mkForce true;
+
+
settings.iconTheme = {
+
name = "Yaru-dark";
+
package = pkgs.yaru-theme;
+
};
+
+
home.pointerCursor = {
+
package = pkgs.bibata-cursors;
+
name = "Bibata-Modern-Classic";
+
size = 24;
+
gtk.enable = true;
+
x11.enable = true;
+
};
gtk.enable = true;
-
x11.enable = true;
-
};
-
gtk.enable = true;
-
gtk.theme.package = pkgs.yaru-theme;
-
gtk.theme.name = "Yaru-dark";
+
gtk.theme.package = pkgs.yaru-theme;
+
gtk.theme.name = "Yaru-dark";
-
# home.sessionVariables.QT_QPA_PLATFORMTHEME = "qt5ct";
-
# xdg.configFile = {
-
# "environment.d/20-apply-qtct.conf".text = ''
-
# QT_QPA_PLATFORMTHEME=qt5ct
-
# '';
-
# };
-
# qt.enable = true;
-
# qt.platformTheme = "qtct";
-
# qt.style.name = "phantom";
-
# qt.style.package = pkgs.phantom;
+
# home.sessionVariables.QT_QPA_PLATFORMTHEME = "qt5ct";
+
# xdg.configFile = {
+
# "environment.d/20-apply-qtct.conf".text = ''
+
# QT_QPA_PLATFORMTHEME=qt5ct
+
# '';
+
# };
+
# qt.enable = true;
+
# qt.platformTheme = "qtct";
+
# qt.style.name = "phantom";
+
# qt.style.package = pkgs.phantom;
-
stylix.targets.gnome.enable = lib.mkForce false;
-
stylix.targets.gtk.enable = lib.mkForce false;
+
stylix.targets.gnome.enable = lib.mkForce false;
+
stylix.targets.gtk.enable = lib.mkForce false;
-
home = {
-
homeDirectory = nixosConfig.users.users.patriot.home;
-
packages = with pkgs; [
-
# Font stuff
-
noto-fonts-cjk
-
font-awesome
-
dejavu_fonts
-
# Programs
-
pixelorama
-
krita
-
gnupg
-
imv
-
mpv
-
ffmpeg
-
mupdf
-
xdg-utils
-
protontricks
-
libreoffice-fresh
-
helvum
-
nix-output-monitor
-
inputs.nh.packages.${pkgs.system}.default
-
# steamPackages.steamcmd
-
# steam-tui
-
# fractal-next
-
# gtkcord4
-
# gh
-
transmission_4-gtk
-
kdenlive
-
### music prod
-
yabridge
-
yabridgectl
-
bitwig-studio
-
### stream / record
-
obs-studio
-
### gayming
-
# prismlauncher
-
# (retroarch.override {
-
# cores = with libretro; [desmume citra];
-
# })
-
# yuzu
-
# wineWowPackages.stagingFull
-
# lutris
-
# distrobox
-
bottles
-
blender
-
];
-
};
-
programs = {
-
musikcube.enable = true;
-
command-not-found.enable =
-
nixosConfig.programs.command-not-found.enable;
-
git = {
-
userName = name;
-
userEmail = email;
-
extraConfig = {
-
gpg.format = "ssh";
-
commit.gpgsign = true;
-
user.signingkey = builtins.readFile ../../secrets/yusdacra.key.pub;
-
};
+
home = {
+
homeDirectory = nixosConfig.users.users.patriot.home;
+
packages = with pkgs; [
+
# Font stuff
+
noto-fonts-cjk
+
font-awesome
+
dejavu_fonts
+
# Programs
+
pixelorama
+
krita
+
gnupg
+
imv
+
mpv
+
ffmpeg
+
mupdf
+
xdg-utils
+
protontricks
+
libreoffice-fresh
+
helvum
+
nix-output-monitor
+
inputs.nh.packages.${pkgs.system}.default
+
# steamPackages.steamcmd
+
# steam-tui
+
# fractal-next
+
# gtkcord4
+
# gh
+
transmission_4-gtk
+
kdenlive
+
### music prod
+
yabridge
+
yabridgectl
+
bitwig-studio
+
### stream / record
+
obs-studio
+
### gayming
+
# prismlauncher
+
# (retroarch.override {
+
# cores = with libretro; [desmume citra];
+
# })
+
# yuzu
+
# wineWowPackages.stagingFull
+
# lutris
+
# distrobox
+
bottles
+
blender
+
];
};
-
};
-
services = {
-
musikcubed = {
-
enable = true;
-
settings.password = "somethingidk";
+
programs = {
+
musikcube.enable = true;
+
command-not-found.enable = nixosConfig.programs.command-not-found.enable;
+
git = {
+
userName = name;
+
userEmail = email;
+
extraConfig = {
+
gpg.format = "ssh";
+
commit.gpgsign = true;
+
user.signingkey = builtins.readFile ../../secrets/yusdacra.key.pub;
+
};
+
};
};
-
gpg-agent = let
-
defaultCacheTtl = 3600 * 6;
-
maxCacheTtl = 3600 * 24;
-
in {
-
inherit defaultCacheTtl maxCacheTtl;
-
enable = true;
-
enableSshSupport = true;
-
sshKeys = ["8369D9CA26C3EAAAB8302A88CEE6FD14B58AA965"];
-
defaultCacheTtlSsh = defaultCacheTtl;
-
maxCacheTtlSsh = maxCacheTtl;
-
grabKeyboardAndMouse = false;
-
pinentryFlavor = "gnome3";
+
services = {
+
musikcubed = {
+
enable = true;
+
settings.password = "somethingidk";
+
};
+
gpg-agent =
+
let
+
defaultCacheTtl = 3600 * 6;
+
maxCacheTtl = 3600 * 24;
+
in
+
{
+
inherit defaultCacheTtl maxCacheTtl;
+
enable = true;
+
enableSshSupport = true;
+
sshKeys = [ "8369D9CA26C3EAAAB8302A88CEE6FD14B58AA965" ];
+
defaultCacheTtlSsh = defaultCacheTtl;
+
maxCacheTtlSsh = maxCacheTtl;
+
grabKeyboardAndMouse = false;
+
pinentryFlavor = "gnome3";
+
};
};
};
-
};
}
+34 -31
users/patriot/stylix.nix
···
pkgs,
lib,
...
-
}: {
+
}:
+
{
imports = [
inputs.stylix.nixosModules.stylix
];
···
# "base0E" = "fffe27"; # splatoon 3 yellow
# "base0F" = "bdbebc";
# };
-
stylix.base16Scheme = let
-
night = "#2b292d";
-
ash = "#383539";
-
umber = "#4d424b";
-
bark = "#6F5D63";
-
mist = "#D1D1E0";
-
sage = "#B1B695";
-
blush = "#fecdb2";
-
coral = "#ffa07a";
-
rose = "#F6B6C9";
-
ember = "#e06b75";
-
honey = "#F5D76E";
-
in {
-
base00 = night;
-
base01 = ash;
-
base02 = umber;
-
base03 = bark;
-
base04 = blush;
-
base05 = mist;
-
base06 = mist;
-
base07 = bark;
-
base08 = ember;
-
base09 = honey;
-
base0A = rose;
-
base0B = sage;
-
base0C = bark;
-
base0D = coral;
-
base0E = blush;
-
base0F = umber;
-
};
+
stylix.base16Scheme =
+
let
+
night = "#2b292d";
+
ash = "#383539";
+
umber = "#4d424b";
+
bark = "#6F5D63";
+
mist = "#D1D1E0";
+
sage = "#B1B695";
+
blush = "#fecdb2";
+
coral = "#ffa07a";
+
rose = "#F6B6C9";
+
ember = "#e06b75";
+
honey = "#F5D76E";
+
in
+
{
+
base00 = night;
+
base01 = ash;
+
base02 = umber;
+
base03 = bark;
+
base04 = blush;
+
base05 = mist;
+
base06 = mist;
+
base07 = bark;
+
base08 = ember;
+
base09 = honey;
+
base0A = rose;
+
base0B = sage;
+
base0C = bark;
+
base0D = coral;
+
base0E = blush;
+
base0F = umber;
+
};
stylix.fonts = {
serif = {
+2 -1
users/root/default.nix
···
-
{...}: {
+
{ ... }:
+
{
users.users.root.initialHashedPassword = "$6$XLWo1sPpgp63Zm$XHBbULH9q1gb/.yalPPU/I7EgTcW80bM.moCjIe/qGyOwE47VcXNVbTHloBZdIWQq0MfIG0IxInAu59.oJyos/";
}