mirror of
https://github.com/gensokyo-zone/infrastructure.git
synced 2026-02-09 04:19:19 -08:00
nixpkgs-fmt for no particular reason
This commit is contained in:
parent
6c74d503fd
commit
c5e4be592c
57 changed files with 1211 additions and 1118 deletions
|
|
@ -8,21 +8,24 @@ with lib; {
|
|||
gh-actions.env.CACHIX_SIGNING_KEY = "\${{ secrets.CACHIX_SIGNING_KEY }}";
|
||||
|
||||
gh-actions = {
|
||||
on = let
|
||||
on =
|
||||
let
|
||||
paths = [
|
||||
"default.nix" # sourceCache
|
||||
"ci/niv-cron.nix" config.ci.gh-actions.path
|
||||
"ci/niv-cron.nix"
|
||||
config.ci.gh-actions.path
|
||||
];
|
||||
in {
|
||||
in
|
||||
{
|
||||
push = {
|
||||
inherit paths;
|
||||
};
|
||||
pull_request = {
|
||||
inherit paths;
|
||||
};
|
||||
schedule = [ {
|
||||
schedule = [{
|
||||
cron = "0 0 * * *";
|
||||
} ];
|
||||
}];
|
||||
};
|
||||
};
|
||||
|
||||
|
|
@ -46,13 +49,16 @@ with lib; {
|
|||
};
|
||||
displayName = "niv update build";
|
||||
environment = [ "OPENSSH_PRIVATE_KEY" "CACHIX_SIGNING_KEY" "GITHUB_REF" ];
|
||||
command = let main = (import ../.);
|
||||
command =
|
||||
let
|
||||
main = (import ../.);
|
||||
hosts = main.network.nodes;
|
||||
targets = main.deploy.targets;
|
||||
enabledTargets = filterAttrs (_: v: v.enable) main.deploy.targets;
|
||||
enabledHosts = concatLists (mapAttrsToList (targetName: target: target.nodeNames) enabledTargets);
|
||||
hostBuildString = concatMapStringsSep " && " (host: "nix build -Lf . network.nodes.${host}.deploy.system -o result-${host} && nix-collect-garbage -d") enabledHosts;
|
||||
in ''
|
||||
in
|
||||
''
|
||||
# ${toString builtins.currentTime}
|
||||
if [[ -n $OPENSSH_PRIVATE_KEY ]]; then
|
||||
mkdir ~/.ssh
|
||||
|
|
|
|||
10
ci/nodes.nix
10
ci/nodes.nix
|
|
@ -6,7 +6,8 @@
|
|||
|
||||
# ensure sources are fetched and available in the local store before evaluating host configs
|
||||
environment.bootstrap = {
|
||||
sourceCache = channels.cipkgs.runCommand "sources" {
|
||||
sourceCache = channels.cipkgs.runCommand "sources"
|
||||
{
|
||||
srcs = attrNames channels.nixfiles.sourceCache.local;
|
||||
} ''
|
||||
mkdir -p $out/share/sources
|
||||
|
|
@ -14,12 +15,15 @@
|
|||
'';
|
||||
};
|
||||
|
||||
jobs = let main = (import ../.);
|
||||
jobs =
|
||||
let
|
||||
main = (import ../.);
|
||||
hosts = main.network.nodes;
|
||||
targets = main.deploy.targets;
|
||||
enabledTargets = filterAttrs (_: v: v.enable) main.deploy.targets;
|
||||
enabledHosts = concatLists (mapAttrsToList (targetName: target: target.nodeNames) enabledTargets);
|
||||
in mapAttrs' (k: nameValuePair "${k}") (genAttrs enabledHosts (host: {
|
||||
in
|
||||
mapAttrs' (k: nameValuePair "${k}") (genAttrs enabledHosts (host: {
|
||||
tasks.${host}.inputs = channels.nixfiles.network.nodes.${host}.deploy.system;
|
||||
}));
|
||||
|
||||
|
|
|
|||
|
|
@ -15,4 +15,4 @@ with lib;
|
|||
"VGA-1" = middle;
|
||||
};
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,7 +5,8 @@ with lib;
|
|||
{
|
||||
wayland.windowManager.sway = {
|
||||
config = {
|
||||
output = let
|
||||
output =
|
||||
let
|
||||
left = {
|
||||
res = "1920x1080";
|
||||
pos = "0 0";
|
||||
|
|
|
|||
|
|
@ -6,7 +6,8 @@ let
|
|||
hexchen = (import sources.hexchen) { };
|
||||
hexYgg = filterAttrs (_: c: c.enable)
|
||||
(mapAttrs (_: host: host.config.network.yggdrasil) hexchen.hosts);
|
||||
in {
|
||||
in
|
||||
{
|
||||
# Imports
|
||||
|
||||
imports = with meta; [
|
||||
|
|
@ -72,13 +73,16 @@ in {
|
|||
environment.systemPackages = [ pkgs.razergenie ];
|
||||
|
||||
boot.modprobe.modules = {
|
||||
vfio-pci = let
|
||||
vfio-pci =
|
||||
let
|
||||
vfio-pci-ids = [
|
||||
"1002:67df" "1002:aaf0" # RX 580
|
||||
"1002:67df"
|
||||
"1002:aaf0" # RX 580
|
||||
"1912:0014" # Renesas USB 3
|
||||
"1022:149c" # CPU USB 3
|
||||
];
|
||||
in mkIf (vfio-pci-ids != [ ]) {
|
||||
in
|
||||
mkIf (vfio-pci-ids != [ ]) {
|
||||
options.ids = concatStringsSep "," vfio-pci-ids;
|
||||
};
|
||||
};
|
||||
|
|
@ -108,7 +112,7 @@ in {
|
|||
};
|
||||
networks.br = {
|
||||
matchConfig.Name = "br";
|
||||
address = singleton "${config.network.addresses.private.ipv4.address}/24" ;
|
||||
address = singleton "${config.network.addresses.private.ipv4.address}/24";
|
||||
gateway = singleton config.network.privateGateway;
|
||||
};
|
||||
netdevs.br = {
|
||||
|
|
|
|||
|
|
@ -4,7 +4,8 @@ with lib;
|
|||
|
||||
{
|
||||
wayland.windowManager.sway.config = {
|
||||
output = let
|
||||
output =
|
||||
let
|
||||
laptop = {
|
||||
res = "1920x1080";
|
||||
pos = "0 0";
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ config, lib, ... }:
|
||||
|
||||
/*
|
||||
This module:
|
||||
This module:
|
||||
* Provides in-scope TF config for home-manager.
|
||||
*/
|
||||
|
||||
|
|
|
|||
|
|
@ -1,13 +1,14 @@
|
|||
{ config, lib, ... }:
|
||||
|
||||
/*
|
||||
This module:
|
||||
This module:
|
||||
* provides a central way to change the font my system uses.
|
||||
*/
|
||||
|
||||
with lib;
|
||||
|
||||
let cfg = config.kw; in {
|
||||
let cfg = config.kw; in
|
||||
{
|
||||
options.kw = {
|
||||
hexColors = mkOption {
|
||||
type = types.attrsOf types.str;
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
/*
|
||||
This module:
|
||||
This module:
|
||||
* is from an unmerged PR from home-manager.
|
||||
|
||||
See: https://github.com/nix-community/home-manager/pull/1745
|
||||
See: https://github.com/nix-community/home-manager/pull/1745
|
||||
*/
|
||||
|
||||
with lib;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ sources, config, pkgs, lib, ... }:
|
||||
|
||||
/*
|
||||
This module:
|
||||
This module:
|
||||
* makes tf-nix a part of the meta config
|
||||
* handles the trusted import for tf-nix
|
||||
* provides the target interface
|
||||
|
|
@ -25,7 +25,8 @@ let
|
|||
./secrets.nix
|
||||
];
|
||||
};
|
||||
in {
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
(toString (sources.tf-nix + "/modules/run.nix"))
|
||||
] ++ (optional (builtins.pathExists ../../trusted/tf/tf.nix) (../../trusted/tf/tf.nix));
|
||||
|
|
@ -41,12 +42,15 @@ in {
|
|||
};
|
||||
hostName = mkOption {
|
||||
type = types.nullOr types.str;
|
||||
default = let
|
||||
default =
|
||||
let
|
||||
hostName = builtins.getEnv "HOME_HOSTNAME";
|
||||
in if hostName == "" then null else hostName;
|
||||
in
|
||||
if hostName == "" then null else hostName;
|
||||
};
|
||||
};
|
||||
targets = let
|
||||
targets =
|
||||
let
|
||||
type = types.submodule ({ config, name, ... }: {
|
||||
options = {
|
||||
enable = mkEnableOption "Enable the target" // { default = true; };
|
||||
|
|
@ -63,7 +67,8 @@ in {
|
|||
default = { };
|
||||
};
|
||||
};
|
||||
config.tf = mkMerge (singleton {
|
||||
config.tf = mkMerge (singleton
|
||||
{
|
||||
imports = [
|
||||
../../targets/common
|
||||
];
|
||||
|
|
@ -94,29 +99,40 @@ in {
|
|||
continue.envVar = "TF_NIX_CONTINUE_${replaceStrings [ "-" ] [ "_" ] config.name}";
|
||||
} ++ map (nodeName: mapAttrs (_: mkMerge) meta.network.nodes.${nodeName}.deploy.tf.out.set) config.nodeNames);
|
||||
});
|
||||
in mkOption {
|
||||
in
|
||||
mkOption {
|
||||
type = types.attrsOf type;
|
||||
default = { };
|
||||
};
|
||||
};
|
||||
};
|
||||
config = {
|
||||
deploy.targets = let
|
||||
deploy.targets =
|
||||
let
|
||||
nodeNames = attrNames config.network.nodes;
|
||||
targets = config.deploy.targets;
|
||||
explicitlyDefinedHosts = concatLists (mapAttrsToList (targetName: target: remove targetName target.nodeNames) config.deploy.targets);
|
||||
in genAttrs nodeNames ( nodeName: {
|
||||
in
|
||||
genAttrs nodeNames (nodeName: {
|
||||
enable = mkDefault (! elem nodeName explicitlyDefinedHosts);
|
||||
nodeNames = singleton nodeName;
|
||||
});
|
||||
|
||||
runners = {
|
||||
run = mkMerge (mapAttrsToList (targetName: target: mapAttrs' (k: run:
|
||||
run = mkMerge (mapAttrsToList
|
||||
(targetName: target: mapAttrs'
|
||||
(k: run:
|
||||
nameValuePair run.name run.set
|
||||
) target.tf.runners.run) (filterAttrs (_: v: v.enable) cfg.targets));
|
||||
lazy.run = mkMerge (mapAttrsToList (targetName: target: mapAttrs' (k: run:
|
||||
)
|
||||
target.tf.runners.run)
|
||||
(filterAttrs (_: v: v.enable) cfg.targets));
|
||||
lazy.run = mkMerge (mapAttrsToList
|
||||
(targetName: target: mapAttrs'
|
||||
(k: run:
|
||||
nameValuePair run.name run.set
|
||||
) target.tf.runners.lazy.run) (filterAttrs (_: v: v.enable) cfg.targets));
|
||||
)
|
||||
target.tf.runners.lazy.run)
|
||||
(filterAttrs (_: v: v.enable) cfg.targets));
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ pkgs, sources, lib, meta, config, ... }:
|
||||
|
||||
/*
|
||||
This module:
|
||||
This module:
|
||||
* Makes hosts nixosModules.
|
||||
* Manages module imports and specialArgs.
|
||||
* Builds network.nodes.
|
||||
|
|
@ -25,7 +25,8 @@ with lib;
|
|||
default = toString (pkgs.path + "/nixos/modules");
|
||||
};
|
||||
};
|
||||
nodes = let
|
||||
nodes =
|
||||
let
|
||||
nixosModule = { name, config, meta, modulesPath, lib, ... }: with lib; {
|
||||
config = {
|
||||
nixpkgs = {
|
||||
|
|
@ -34,9 +35,11 @@ with lib;
|
|||
};
|
||||
};
|
||||
};
|
||||
nixosType = let
|
||||
nixosType =
|
||||
let
|
||||
baseModules = import (config.network.nixos.modulesPath + "/module-list.nix");
|
||||
in types.submoduleWith {
|
||||
in
|
||||
types.submoduleWith {
|
||||
modules = baseModules
|
||||
++ singleton nixosModule
|
||||
++ config.network.nixos.extraModules;
|
||||
|
|
@ -46,7 +49,8 @@ with lib;
|
|||
inherit (config.network.nixos) modulesPath;
|
||||
} // config.network.nixos.specialArgs;
|
||||
};
|
||||
in mkOption {
|
||||
in
|
||||
mkOption {
|
||||
type = types.attrsOf nixosType;
|
||||
default = { };
|
||||
};
|
||||
|
|
|
|||
|
|
@ -3,7 +3,8 @@
|
|||
with lib;
|
||||
|
||||
{
|
||||
options = let tf = config; in {
|
||||
options = let tf = config; in
|
||||
{
|
||||
variables = mkOption {
|
||||
type = types.attrsOf (types.submodule ({ name, config, ... }: {
|
||||
options.externalSecret = mkEnableOption "Is ths secret to be templated into a command provided?";
|
||||
|
|
|
|||
|
|
@ -20,6 +20,6 @@
|
|||
This maps hosts to network.nodes from the meta config. This is required for hexchen's yggdrasil network module.
|
||||
*/
|
||||
config = {
|
||||
_module.args.hosts = lib.mapAttrs (_: config: { inherit config; } ) meta.network.nodes;
|
||||
_module.args.hosts = lib.mapAttrs (_: config: { inherit config; }) meta.network.nodes;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ tf, target, name, meta, config, lib, ... }:
|
||||
|
||||
/*
|
||||
This module:
|
||||
This module:
|
||||
* aliases <hostname>.system.build.toplevel to <hostname>.deploy.system for ease of use.
|
||||
* marries meta config to NixOS configs for each host.
|
||||
* provides in-scope TF config in NixOS and home-manager, instead of only as a part of meta config.
|
||||
|
|
@ -53,11 +53,12 @@ in
|
|||
config = {
|
||||
deploy = {
|
||||
system = config.system.build.toplevel;
|
||||
targetName = let targetsList = attrNames ( filterAttrs (_: target: target.enable && elem name target.nodeNames) meta.deploy.targets ); in
|
||||
targetName = let targetsList = attrNames (filterAttrs (_: target: target.enable && elem name target.nodeNames) meta.deploy.targets); in
|
||||
if (builtins.length targetsList == 0) then null
|
||||
else lib.warnIf (builtins.length targetsList > 1) "The host ${name} is assigned to several targets: ${concatMapStrings (x: "${x},") targetsList}." (head targetsList);
|
||||
};
|
||||
deploy.tf = mkMerge (singleton (lib.mkIf (config.deploy.targetName != null) {
|
||||
deploy.tf = mkMerge (singleton
|
||||
(lib.mkIf (config.deploy.targetName != null) {
|
||||
attrs = [ "import" "imports" "out" "attrs" ];
|
||||
import = genAttrs cfg.tf.imports (target: meta.deploy.targets.${target}.tf);
|
||||
out.set = removeAttrs cfg.tf cfg.tf.attrs;
|
||||
|
|
|
|||
|
|
@ -34,7 +34,8 @@ with lib;
|
|||
${pkgs.curl}/bin/curl -u ''${user}:''${pass} --data-urlencode "hostname=''${hostname}" --data-urlencode "myip=''${ip4}" "https://dns.glauca.digital/nic/update"
|
||||
echo ""
|
||||
${pkgs.curl}/bin/curl -u ''${user}:''${pass} --data-urlencode "hostname=''${hostname}" --data-urlencode "myip=''${ip6}" "https://dns.glauca.digital/nic/update"
|
||||
''; in {
|
||||
''; in
|
||||
{
|
||||
serviceConfig = {
|
||||
ExecStart = "${updater}/bin/glauca-dyndns";
|
||||
};
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
boot.zfs.enableUnstable = true;
|
||||
boot.kernel.sysctl = {
|
||||
"net.core.rmem_max" = "16777216";
|
||||
"net.core.wmem_max" ="16777216";
|
||||
"net.core.wmem_max" = "16777216";
|
||||
"net.ipv4.tcp_rmem" = "4096 87380 16777216";
|
||||
"net.ipv4.tcp_wmem" = "4096 65536 16777216";
|
||||
};
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
fileSystems."/mnt/kat-nas" = lib.mkIf (config.networking.hostName != "beltane") {
|
||||
device = "${meta.network.nodes.beltane.network.addresses.private.domain}:/mnt/zraw/media";
|
||||
fsType = "nfs";
|
||||
options = [ "x-systemd.automount" "noauto" "nfsvers=4" "soft" "retrans=2" "timeo=60"];
|
||||
options = [ "x-systemd.automount" "noauto" "nfsvers=4" "soft" "retrans=2" "timeo=60" ];
|
||||
};
|
||||
|
||||
/*
|
||||
|
|
|
|||
|
|
@ -1,11 +1,12 @@
|
|||
let hardwareProfiles = { lib }:
|
||||
let profiles = with profiles; lib.domainMerge {
|
||||
let profiles = with profiles; lib.domainMerge
|
||||
{
|
||||
folder = ""; # not used in this usage
|
||||
folderPaths = [
|
||||
./.
|
||||
../../trusted/profiles/hardware
|
||||
];
|
||||
} // {
|
||||
} // {
|
||||
ms-7b86 = {
|
||||
imports = [
|
||||
ms-7b86-base
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ config, lib, sources, ... }:
|
||||
|
||||
/*
|
||||
This hardware profile corresponds with the imperatively provisioned hetzner cloud box.
|
||||
This hardware profile corresponds with the imperatively provisioned hetzner cloud box.
|
||||
*/
|
||||
|
||||
with lib;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ config, ... }:
|
||||
|
||||
/*
|
||||
This hardware profile corresponds to any machine which has an Intel processor.
|
||||
This hardware profile corresponds to any machine which has an Intel processor.
|
||||
*/
|
||||
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ config, lib, ... }:
|
||||
|
||||
/*
|
||||
This hardware profile corresponds to the MSI B450-A PRO MAX system.
|
||||
This hardware profile corresponds to the MSI B450-A PRO MAX system.
|
||||
*/
|
||||
|
||||
with lib;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ config, ... }:
|
||||
|
||||
/*
|
||||
This hardware profile corresponds with the RM DESKTOP 310 system, which is actually just an Intel DQ67OW motherboard.
|
||||
This hardware profile corresponds with the RM DESKTOP 310 system, which is actually just an Intel DQ67OW motherboard.
|
||||
*/
|
||||
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
/*
|
||||
This hardware profile corresponds to any machine which has an AMD Ryzen processor.
|
||||
This hardware profile corresponds to any machine which has an AMD Ryzen processor.
|
||||
*/
|
||||
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{ config, ... }:
|
||||
|
||||
/*
|
||||
This hardware profile corresponds to the Lenovo IdeaPad v330-14ARR.
|
||||
This hardware profile corresponds to the Lenovo IdeaPad v330-14ARR.
|
||||
*/
|
||||
|
||||
{
|
||||
|
|
|
|||
|
|
@ -9,7 +9,8 @@ let
|
|||
win10-diskmapper = pkgs.writeShellScriptBin "win10-diskmapper" ''
|
||||
sudo ${pkgs.disk-mapper}/bin/disk-mapper /dev/disk/by-id/ata-ST2000DM008-2FR102_WK301C3H-part2
|
||||
'';
|
||||
in {
|
||||
in
|
||||
{
|
||||
deploy.profile.vfio = true;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
|
|
@ -23,25 +24,27 @@ in {
|
|||
users.users.kat.extraGroups = [ "vfio" "input" "uinput" ];
|
||||
users.groups = { uinput = { }; vfio = { }; };
|
||||
|
||||
boot = lib.mkMerge [ {
|
||||
initrd.kernelModules = mkBefore ["vfio" "vfio_iommu_type1" "vfio_pci" "vfio_virqfd"];
|
||||
boot = lib.mkMerge [{
|
||||
initrd.kernelModules = mkBefore [ "vfio" "vfio_iommu_type1" "vfio_pci" "vfio_virqfd" ];
|
||||
kernelModules = [ "i2c-dev" ]; # i2c-dev is required for DDC/CI for screenstub
|
||||
kernelPatches = with pkgs.kernelPatches; [
|
||||
(mkIf config.deploy.profile.hardware.acs-override acs-override)
|
||||
];
|
||||
} (mkIf (config.deploy.profile.hardware.amdgpu) {
|
||||
}
|
||||
(mkIf (config.deploy.profile.hardware.amdgpu) {
|
||||
kernelParams = [
|
||||
"video=efifb:off"
|
||||
];
|
||||
extraModulePackages = [
|
||||
(pkgs.linuxPackagesFor config.boot.kernelPackages.kernel).vendor-reset
|
||||
];
|
||||
}) ( mkIf (config.deploy.profile.hardware.acs-override) {
|
||||
})
|
||||
(mkIf (config.deploy.profile.hardware.acs-override) {
|
||||
kernelParams = [
|
||||
"pci=noats"
|
||||
"pcie_acs_override=downstream,multifunction"
|
||||
];
|
||||
}) ];
|
||||
})];
|
||||
|
||||
environment.etc."qemu/bridge.conf".text = "allow br";
|
||||
|
||||
|
|
|
|||
|
|
@ -1,8 +1,9 @@
|
|||
{ config, pkgs, kw, ... }:
|
||||
|
||||
let splashy = pkgs.host-splash-site config.networking.hostName; in {
|
||||
let splashy = pkgs.host-splash-site config.networking.hostName; in
|
||||
{
|
||||
services.nginx.virtualHosts = kw.virtualHostGen {
|
||||
networkFilter = ["private"];
|
||||
networkFilter = [ "private" ];
|
||||
block.locations."/" = { root = splashy; };
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
{ config, pkgs, lib , ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
|
||||
|
|
@ -94,7 +94,8 @@ let
|
|||
|
||||
rtmpsink
|
||||
];
|
||||
in {
|
||||
in
|
||||
{
|
||||
services.nginx.appendConfig = ''
|
||||
rtmp {
|
||||
server {
|
||||
|
|
|
|||
|
|
@ -41,7 +41,8 @@ let
|
|||
};
|
||||
}
|
||||
];
|
||||
in {
|
||||
in
|
||||
{
|
||||
services.udev.extraRules = ''
|
||||
KERNEL=="video[0-9]*", SUBSYSTEM=="video4linux", SUBSYSTEMS=="usb", ATTR{index}=="0", ATTRS{idVendor}=="045e", ATTRS{idProduct}=="0779", SYMLINK+="videomew", TAG+="systemd"
|
||||
'';
|
||||
|
|
|
|||
|
|
@ -48,31 +48,31 @@ with lib;
|
|||
enable = true;
|
||||
max_upload_size = "512M";
|
||||
logConfig = ''
|
||||
version: 1
|
||||
version: 1
|
||||
|
||||
# In systemd's journal, loglevel is implicitly stored, so let's omit it
|
||||
# from the message text.
|
||||
formatters:
|
||||
# In systemd's journal, loglevel is implicitly stored, so let's omit it
|
||||
# from the message text.
|
||||
formatters:
|
||||
journal_fmt:
|
||||
format: '%(name)s: [%(request)s] %(message)s'
|
||||
|
||||
filters:
|
||||
filters:
|
||||
context:
|
||||
(): synapse.util.logcontext.LoggingContextFilter
|
||||
request: ""
|
||||
|
||||
handlers:
|
||||
handlers:
|
||||
journal:
|
||||
class: systemd.journal.JournalHandler
|
||||
formatter: journal_fmt
|
||||
filters: [context]
|
||||
SYSLOG_IDENTIFIER: synapse
|
||||
|
||||
root:
|
||||
root:
|
||||
level: WARNING
|
||||
handlers: [journal]
|
||||
|
||||
disable_existing_loggers: False
|
||||
disable_existing_loggers: False
|
||||
'';
|
||||
server_name = config.network.dns.domain;
|
||||
app_service_config_files = [
|
||||
|
|
|
|||
|
|
@ -5,7 +5,8 @@ with lib;
|
|||
let
|
||||
cfg = config.services.murmur;
|
||||
forking = (cfg.logFile != null);
|
||||
in {
|
||||
in
|
||||
{
|
||||
network.firewall = {
|
||||
public = {
|
||||
tcp.ports = singleton 64738;
|
||||
|
|
@ -79,7 +80,7 @@ in {
|
|||
systemd.services.murmur = {
|
||||
description = "Murmur Chat Service";
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
after = [ "network-online.target "];
|
||||
after = [ "network-online.target " ];
|
||||
|
||||
serviceConfig = {
|
||||
# murmurd doesn't fork when logging to the console.
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
{
|
||||
deploy.targets.personal = {
|
||||
nodeNames = [ "samhain" "yule"];
|
||||
nodeNames = [ "samhain" "yule" ];
|
||||
tf = { config, ... }: {
|
||||
dns.records.ygg_grimoire = {
|
||||
tld = "kittywit.ch.";
|
||||
|
|
|
|||
|
|
@ -17,8 +17,9 @@
|
|||
port = 62954;
|
||||
};
|
||||
in
|
||||
(lib.foldAttrList (map (network:
|
||||
lib.mapAttrs (_: v: { hostname = v.address; } // common) (lib.filterAttrs (_: v: v.enable ) (lib.mapAttrs (_: v: v.network.addresses.${network}.ipv4) meta.network.nodes))
|
||||
) ["private" "public"]));
|
||||
(lib.foldAttrList (map
|
||||
(network:
|
||||
lib.mapAttrs (_: v: { hostname = v.address; } // common) (lib.filterAttrs (_: v: v.enable) (lib.mapAttrs (_: v: v.network.addresses.${network}.ipv4) meta.network.nodes))
|
||||
) [ "private" "public" ]));
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
home.sessionVariables.EDITOR = "vim";
|
||||
programs.vim = {
|
||||
enable = true;
|
||||
settings = {};
|
||||
settings = { };
|
||||
package = pkgs.vim_configurable-pynvim;
|
||||
#withPython3 = true;
|
||||
plugins = with pkgs.vimPlugins; [
|
||||
|
|
|
|||
|
|
@ -11,7 +11,8 @@ let
|
|||
fi
|
||||
'';
|
||||
shellFunAliases = mapAttrs shellFunAlias;
|
||||
in {
|
||||
in
|
||||
{
|
||||
home.shell.functions = {
|
||||
genmac = ''
|
||||
nix run nixpkgs.openssl -c openssl rand -hex 6 | sed 's/\(..\)\(..\)\(..\)\(..\)\(..\)\(..\)/\1:\2:\3:\4:\5:\6/'
|
||||
|
|
@ -29,13 +30,31 @@ in {
|
|||
programs.zsh = {
|
||||
enable = true;
|
||||
enableAutosuggestions = true;
|
||||
initExtra = let
|
||||
zshOpts= [
|
||||
"auto_pushd" "pushd_ignore_dups" "pushdminus"
|
||||
"rmstarsilent" "nonomatch" "long_list_jobs" "interactivecomments"
|
||||
"append_history" "hist_ignore_space" "hist_verify" "inc_append_history" "nosharehistory"
|
||||
"nomenu_complete" "auto_menu" "no_auto_remove_slash" "complete_in_word" "always_to_end" "nolistbeep" "autolist" "listrowsfirst"
|
||||
]; in ''
|
||||
initExtra =
|
||||
let
|
||||
zshOpts = [
|
||||
"auto_pushd"
|
||||
"pushd_ignore_dups"
|
||||
"pushdminus"
|
||||
"rmstarsilent"
|
||||
"nonomatch"
|
||||
"long_list_jobs"
|
||||
"interactivecomments"
|
||||
"append_history"
|
||||
"hist_ignore_space"
|
||||
"hist_verify"
|
||||
"inc_append_history"
|
||||
"nosharehistory"
|
||||
"nomenu_complete"
|
||||
"auto_menu"
|
||||
"no_auto_remove_slash"
|
||||
"complete_in_word"
|
||||
"always_to_end"
|
||||
"nolistbeep"
|
||||
"autolist"
|
||||
"listrowsfirst"
|
||||
]; in
|
||||
''
|
||||
zmodload -i zsh/complist
|
||||
zstyle ':completion:*' list-colors ""
|
||||
zstyle ':completion:*:*:*:*:*' menu select
|
||||
|
|
@ -48,14 +67,14 @@ in {
|
|||
bindkey '^ ' autosuggest-accept
|
||||
autoload -Uz history-search-end
|
||||
autoload -Uz history-beginning-search-menu
|
||||
zle -N history-beginning-search-menu
|
||||
zle -N history-beginning-search-backward-end \
|
||||
zle -N history-beginning-search-menu
|
||||
zle -N history-beginning-search-backward-end \
|
||||
history-search-end
|
||||
zle -N history-beginning-search-forward-end \
|
||||
zle -N history-beginning-search-forward-end \
|
||||
history-search-end
|
||||
bindkey "\e[5~" history-beginning-search-backward-end
|
||||
bindkey "\e[6~" history-beginning-search-forward-end
|
||||
bindkey "^p" history-beginning-search-menu
|
||||
bindkey "\e[5~" history-beginning-search-backward-end
|
||||
bindkey "\e[6~" history-beginning-search-forward-end
|
||||
bindkey "^p" history-beginning-search-menu
|
||||
echo ""; akiflags -rb;
|
||||
'';
|
||||
shellAliases = {
|
||||
|
|
|
|||
|
|
@ -1,27 +1,33 @@
|
|||
let katUser = { lib }: let
|
||||
let katUser = { lib }:
|
||||
let
|
||||
trustedImport = {
|
||||
config.home-manager.users.kat = {
|
||||
imports = lib.optional (builtins.pathExists ../../trusted/users/kat) (import ../../trusted/users/kat/home.nix);
|
||||
};
|
||||
}; userImport = profile: { config, ... }: {
|
||||
};
|
||||
userImport = profile: { config, ... }: {
|
||||
config.home-manager.users.kat = {
|
||||
imports = [
|
||||
(./. + "/${profile}")
|
||||
];
|
||||
};
|
||||
}; serviceImport = profile: { config, ... }: {
|
||||
};
|
||||
serviceImport = profile: { config, ... }: {
|
||||
config.home-manager.users.kat = {
|
||||
imports = [
|
||||
(./services + "/${profile}")
|
||||
];
|
||||
};
|
||||
}; profileNames = lib.folderList ./. ["base" "services"];
|
||||
serviceNames = lib.folderList ./services [];
|
||||
userProfiles = with userProfiles;
|
||||
};
|
||||
profileNames = lib.folderList ./. [ "base" "services" ];
|
||||
serviceNames = lib.folderList ./services [ ];
|
||||
userProfiles = with userProfiles;
|
||||
lib.genAttrs profileNames userImport // {
|
||||
services = lib.genAttrs serviceNames serviceImport;
|
||||
base = { imports = [ ./nixos.nix (userImport "base") trustedImport ]; };
|
||||
server = { imports = [ personal ]; };
|
||||
guiFull = { imports = [ gui sway dev media personal ]; };
|
||||
}; in userProfiles;
|
||||
};
|
||||
in
|
||||
userProfiles;
|
||||
in { __functor = self: katUser; isModule = false; }
|
||||
|
|
|
|||
|
|
@ -1,65 +1,66 @@
|
|||
{ config, ... }:
|
||||
|
||||
{
|
||||
home.file.".mozilla/tst.css".text = let base16 = config.kw.hexColors; in ''
|
||||
home.file.".mozilla/tst.css".text = let base16 = config.kw.hexColors; in
|
||||
''
|
||||
/* Hide border on tab bar, force its state to 'scroll', adjust margin-left for width of scrollbar. */
|
||||
#tabbar { border: 0; overflow-y: scroll !important; }
|
||||
|
||||
/* Hide .twisty and adjust margins so favicons have 7px on left. */
|
||||
.tab .twisty {
|
||||
/* Hide .twisty and adjust margins so favicons have 7px on left. */
|
||||
.tab .twisty {
|
||||
margin-left: -16px;
|
||||
}
|
||||
}
|
||||
|
||||
/* Push tab labels slightly to the right so they're completely hidden in collapsed state */
|
||||
.tab .label {
|
||||
/* Push tab labels slightly to the right so they're completely hidden in collapsed state */
|
||||
.tab .label {
|
||||
margin-left: 7px;
|
||||
}
|
||||
/* Hide close buttons on tabs. */
|
||||
.tab .closebox {
|
||||
}
|
||||
/* Hide close buttons on tabs. */
|
||||
.tab .closebox {
|
||||
visibility: collapse;
|
||||
}
|
||||
}
|
||||
|
||||
/* Hide sound playing/muted button. */
|
||||
.sound-button::before {
|
||||
/* Hide sound playing/muted button. */
|
||||
.sound-button::before {
|
||||
display: none !important;
|
||||
}
|
||||
}
|
||||
|
||||
/* Hide 'new tab' button. */
|
||||
.newtab-button {
|
||||
/* Hide 'new tab' button. */
|
||||
.newtab-button {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
/* ################################################ */
|
||||
/* ##### COLOR THEME ############################## */
|
||||
/* ################################################ */
|
||||
@keyframes spin {
|
||||
/* ################################################ */
|
||||
/* ##### COLOR THEME ############################## */
|
||||
/* ################################################ */
|
||||
@keyframes spin {
|
||||
0% {
|
||||
transform: rotate(0deg);
|
||||
}
|
||||
100% {
|
||||
transform: rotate(360deg);
|
||||
}
|
||||
}
|
||||
@keyframes pulse {
|
||||
}
|
||||
@keyframes pulse {
|
||||
0% {
|
||||
opacity: 0.75;
|
||||
}
|
||||
100% {
|
||||
opacity: 0.25;
|
||||
}
|
||||
}
|
||||
* {
|
||||
}
|
||||
* {
|
||||
font-family: "Cozette", monospace !important;
|
||||
}
|
||||
:root {
|
||||
}
|
||||
:root {
|
||||
background-color: ${base16.base00} !important;
|
||||
}
|
||||
#tabbar {
|
||||
}
|
||||
#tabbar {
|
||||
background-color: ${base16.base00} !important;
|
||||
border-right: 1px solid ${base16.base01};
|
||||
box-shadow: none !important;
|
||||
}
|
||||
.tab {
|
||||
}
|
||||
.tab {
|
||||
background-color: ${base16.base01};
|
||||
color: ${base16.base05} !important;
|
||||
box-shadow: none !important;
|
||||
|
|
@ -67,39 +68,39 @@
|
|||
border-radius: 0.125em;
|
||||
}
|
||||
|
||||
.tab .favicon {
|
||||
.tab .favicon {
|
||||
margin-left: 0.25em;
|
||||
}
|
||||
}
|
||||
|
||||
.tab .label {
|
||||
.tab .label {
|
||||
margin: 0.25em;
|
||||
}
|
||||
.tab:hover {
|
||||
}
|
||||
.tab:hover {
|
||||
background-color: ${base16.base0C}FF !important;
|
||||
color: ${base16.base07} !important;
|
||||
}
|
||||
.tab.discarded {
|
||||
}
|
||||
.tab.discarded {
|
||||
background-color: ${base16.base00};
|
||||
color: ${base16.base02} !important;
|
||||
}
|
||||
.tab.discarded:hover {
|
||||
}
|
||||
.tab.discarded:hover {
|
||||
background-color: ${base16.base01} !important;
|
||||
color: ${base16.base03} !important;
|
||||
}
|
||||
}
|
||||
|
||||
:root .tab .highlighter::before {
|
||||
:root .tab .highlighter::before {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
.tab.active {
|
||||
.tab.active {
|
||||
background-color: ${base16.base0D}FF;
|
||||
color: ${base16.base07} !important;
|
||||
}
|
||||
.tab.active:hover {
|
||||
}
|
||||
.tab.active:hover {
|
||||
background-color: ${base16.base0D}FF !important;
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes rainbow_animation {
|
||||
@keyframes rainbow_animation {
|
||||
0% {
|
||||
background-position: 0 0;
|
||||
}
|
||||
|
|
@ -107,8 +108,8 @@
|
|||
100% {
|
||||
background-position: 100% 0;
|
||||
}
|
||||
}
|
||||
/* Adjust style for tab that has sound playing. */
|
||||
}
|
||||
/* Adjust style for tab that has sound playing. */
|
||||
.tab.sound-playing .label {
|
||||
background: linear-gradient(to right, #6666ff, #0099ff , #00ff00, #ff3399, #6666ff);
|
||||
-webkit-background-clip: text;
|
||||
|
|
@ -119,9 +120,9 @@
|
|||
background-size: 400% 100%;
|
||||
}
|
||||
|
||||
/* Adjust style for tab that is muted. */
|
||||
.tab.muted {
|
||||
/* Adjust style for tab that is muted. */
|
||||
.tab.muted {
|
||||
opacity: 0.5;
|
||||
}
|
||||
}
|
||||
'';
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,98 +9,98 @@
|
|||
--animationSpeed : 0.15s;
|
||||
}
|
||||
|
||||
/* Hide main tabs toolbar */
|
||||
#TabsToolbar {
|
||||
/* Hide main tabs toolbar */
|
||||
#TabsToolbar {
|
||||
visibility: collapse;
|
||||
}
|
||||
/* Hide splitter, when using Tree Style Tab. */
|
||||
#sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"] + #sidebar-splitter {
|
||||
}
|
||||
/* Hide splitter, when using Tree Style Tab. */
|
||||
#sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"] + #sidebar-splitter {
|
||||
display: none !important;
|
||||
}
|
||||
/* Hide sidebar header, when using Tree Style Tab. */
|
||||
#sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"] #sidebar-header {
|
||||
}
|
||||
/* Hide sidebar header, when using Tree Style Tab. */
|
||||
#sidebar-box[sidebarcommand="treestyletab_piro_sakura_ne_jp-sidebar-action"] #sidebar-header {
|
||||
visibility: collapse;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#back-button { display: none !important }
|
||||
#forward-button { display: none !important }
|
||||
#urlbar-search-mode-indicator { display: none !important }
|
||||
#urlbar *|input::placeholder { opacity: 0 !important; }
|
||||
#back-button { display: none !important }
|
||||
#forward-button { display: none !important }
|
||||
#urlbar-search-mode-indicator { display: none !important }
|
||||
#urlbar *|input::placeholder { opacity: 0 !important; }
|
||||
|
||||
#nav-bar, toolbar-menubar, #menubar-items, #main-menubar {
|
||||
#nav-bar, toolbar-menubar, #menubar-items, #main-menubar {
|
||||
background: ${base16.base00} !important;
|
||||
}
|
||||
}
|
||||
|
||||
#urlbar-background {
|
||||
#urlbar-background {
|
||||
background: ${base16.base01} !important;
|
||||
}
|
||||
}
|
||||
|
||||
#urlbar {
|
||||
#urlbar {
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
|
||||
#urlbar-container {
|
||||
#urlbar-container {
|
||||
width: 50vw !important;
|
||||
}
|
||||
|
||||
#star-button{
|
||||
#star-button{
|
||||
display:none;
|
||||
}
|
||||
}
|
||||
|
||||
#navigator-toolbox {
|
||||
#navigator-toolbox {
|
||||
border : none !important;
|
||||
}
|
||||
}
|
||||
|
||||
.titlebar-spacer {
|
||||
.titlebar-spacer {
|
||||
display : none !important;
|
||||
}
|
||||
}
|
||||
|
||||
#urlbar:not(:hover):not([breakout][breakout-extend]) > #urlbar-background {
|
||||
#urlbar:not(:hover):not([breakout][breakout-extend]) > #urlbar-background {
|
||||
box-shadow : none !important;
|
||||
background : ${base16.base01} !important;
|
||||
}
|
||||
}
|
||||
|
||||
.urlbar-icon, #userContext-indicator, #userContext-label {
|
||||
.urlbar-icon, #userContext-indicator, #userContext-label {
|
||||
fill : transparent !important;
|
||||
background : transparent !important;
|
||||
color : transparent !important;
|
||||
}
|
||||
}
|
||||
|
||||
#nav-bar-customization-target > toolbarspring { max-width: none !important }
|
||||
#nav-bar-customization-target > toolbarspring { max-width: none !important }
|
||||
|
||||
#urlbar:hover .urlbar-icon,
|
||||
#urlbar:active .urlbar-icon,
|
||||
#urlbar[focused] .urlbar-icon {
|
||||
#urlbar:hover .urlbar-icon,
|
||||
#urlbar:active .urlbar-icon,
|
||||
#urlbar[focused] .urlbar-icon {
|
||||
fill : var(--toolbar-color) !important;
|
||||
}
|
||||
}
|
||||
|
||||
#urlbar-container {
|
||||
#urlbar-container {
|
||||
-moz-box-pack: center !important;
|
||||
}
|
||||
}
|
||||
|
||||
/* animations */
|
||||
toolbarbutton,
|
||||
.toolbarbutton-icon,
|
||||
.subviewbutton,
|
||||
#urlbar-background,
|
||||
.urlbar-icon,
|
||||
#userContext-indicator,
|
||||
#userContext-label,
|
||||
.urlbar-input-box,
|
||||
#identity-box,
|
||||
#tracking-protection-icon-container,
|
||||
[anonid=urlbar-go-button],
|
||||
.urlbar-icon-wrapper,
|
||||
#tracking-protection-icon,
|
||||
#identity-box image,
|
||||
stack,
|
||||
vbox,
|
||||
tab:not(:active) .tab-background,
|
||||
tab:not([beforeselected-visible])::after,
|
||||
tab[visuallyselected] .tab-background::before,
|
||||
tab[visuallyselected] .tab-background::before,
|
||||
.tab-close-button {
|
||||
/* animations */
|
||||
toolbarbutton,
|
||||
.toolbarbutton-icon,
|
||||
.subviewbutton,
|
||||
#urlbar-background,
|
||||
.urlbar-icon,
|
||||
#userContext-indicator,
|
||||
#userContext-label,
|
||||
.urlbar-input-box,
|
||||
#identity-box,
|
||||
#tracking-protection-icon-container,
|
||||
[anonid=urlbar-go-button],
|
||||
.urlbar-icon-wrapper,
|
||||
#tracking-protection-icon,
|
||||
#identity-box image,
|
||||
stack,
|
||||
vbox,
|
||||
tab:not(:active) .tab-background,
|
||||
tab:not([beforeselected-visible])::after,
|
||||
tab[visuallyselected] .tab-background::before,
|
||||
tab[visuallyselected] .tab-background::before,
|
||||
.tab-close-button {
|
||||
transition : var(--animationSpeed) !important;
|
||||
}
|
||||
}
|
||||
''
|
||||
|
|
|
|||
|
|
@ -77,7 +77,9 @@
|
|||
"m" = vim."`";
|
||||
"WHEEL_UP" = vim."L";
|
||||
"WHEEL_DOWN" = vim."H";
|
||||
}; in vim // other;
|
||||
};
|
||||
in
|
||||
vim // other;
|
||||
config = {
|
||||
no-input-default-bindings = "";
|
||||
profile = "gpu-hq";
|
||||
|
|
@ -108,4 +110,4 @@
|
|||
});
|
||||
};
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -39,14 +39,15 @@
|
|||
|
||||
services.weechat.enable = true;
|
||||
|
||||
systemd.user.services.weechat-tmux = let scfg = config.services.weechat; in lib.mkForce {
|
||||
systemd.user.services.weechat-tmux = let scfg = config.services.weechat; in
|
||||
lib.mkForce {
|
||||
Unit = {
|
||||
Description = "Weechat tmux session";
|
||||
After = [ "network.target" ];
|
||||
};
|
||||
Service = {
|
||||
Type = "oneshot";
|
||||
Environment=[
|
||||
Environment = [
|
||||
"TMUX_TMPDIR=%t"
|
||||
"WEECHAT_HOME=${toString config.programs.weechat.homeDirectory}"
|
||||
];
|
||||
|
|
|
|||
|
|
@ -5,11 +5,12 @@ let
|
|||
exec foot "$2"
|
||||
'';
|
||||
lockCommand = "${pkgs.swaylock-fancy}/bin/swaylock-fancy -d -t ''";
|
||||
in {
|
||||
in
|
||||
{
|
||||
home.sessionVariables = {
|
||||
XDG_CURRENT_DESKTOP = "sway";
|
||||
XDG_SESSION_TYPE = "wayland";
|
||||
WLR_DRM_DEVICES="/dev/dri/card0";
|
||||
WLR_DRM_DEVICES = "/dev/dri/card0";
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [ grim slurp swaylock-fancy wl-clipboard jq quintom-cursor-theme gsettings-desktop-schemas glib wofi wmctrl ];
|
||||
|
|
@ -55,7 +56,8 @@ in {
|
|||
fi
|
||||
'';
|
||||
|
||||
wayland.windowManager.sway = let
|
||||
wayland.windowManager.sway =
|
||||
let
|
||||
cfg = config.wayland.windowManager.sway.config;
|
||||
bindsym = k: v: "bindsym ${k} ${v}";
|
||||
bindWorkspace = key: workspace: {
|
||||
|
|
@ -90,12 +92,15 @@ in {
|
|||
];
|
||||
workspaceBindings' = map (lib.mapAttrsToList bindsym) workspaceBindings;
|
||||
workspaceBindingsStr = lib.concatStringsSep "\n" (lib.flatten workspaceBindings');
|
||||
in {
|
||||
in
|
||||
{
|
||||
enable = true;
|
||||
config = let
|
||||
config =
|
||||
let
|
||||
pactl = "${config.home.nixosConfig.hardware.pulseaudio.package or pkgs.pulseaudio}/bin/pactl";
|
||||
dmenu = "${pkgs.wofi}/bin/wofi -idbt ${footwrap}/bin/footwrap -s ~/.config/wofi/wofi.css -p '' -W 25%";
|
||||
in {
|
||||
in
|
||||
{
|
||||
|
||||
modes = {
|
||||
"System (l) lock, (e) logout, (s) suspend, (h) hibernate, (r) reboot, (Shift+s) shutdown" =
|
||||
|
|
@ -281,7 +286,8 @@ in {
|
|||
"${cfg.modifier}+Delete" = ''mode "System (l) lock, (e) logout, (s) suspend, (h) hibernate, (r) reboot, (Shift+s) shutdown"'';
|
||||
};
|
||||
|
||||
colors = let base16 = config.kw.hexColors; in {
|
||||
colors = let base16 = config.kw.hexColors; in
|
||||
{
|
||||
focused = {
|
||||
border = base16.base01;
|
||||
background = base16.base0D;
|
||||
|
|
@ -359,4 +365,4 @@ in {
|
|||
${workspaceBindingsStr}
|
||||
'';
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,7 +5,8 @@ let
|
|||
color: ${color};
|
||||
border-color: ${color};
|
||||
'';
|
||||
in ''
|
||||
in
|
||||
''
|
||||
* {
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
let
|
||||
base16 = config.kw.hexColors;
|
||||
in
|
||||
{
|
||||
{
|
||||
programs.waybar = {
|
||||
enable = true;
|
||||
style = import ./waybar.css.nix {
|
||||
|
|
@ -13,7 +13,7 @@ in
|
|||
};
|
||||
settings = [{
|
||||
modules-left = [ "sway/workspaces" "sway/mode" "sway/window" ];
|
||||
modules-center = ["clock" "clock#arc" "clock#miku" "clock#hex" ];
|
||||
modules-center = [ "clock" "clock#arc" "clock#miku" "clock#hex" ];
|
||||
modules-right = [
|
||||
"pulseaudio"
|
||||
"cpu"
|
||||
|
|
@ -130,4 +130,4 @@ in
|
|||
};
|
||||
}];
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,8 @@
|
|||
{ config, lib, ... }:
|
||||
|
||||
{
|
||||
xdg.configFile."wofi/wofi.css".text = let base16 = config.kw.hexColors; in ''
|
||||
xdg.configFile."wofi/wofi.css".text = let base16 = config.kw.hexColors; in
|
||||
''
|
||||
#scroll, #input {
|
||||
background: ${base16.base01};
|
||||
}
|
||||
|
|
|
|||
24
default.nix
24
default.nix
|
|
@ -10,9 +10,10 @@ let
|
|||
getSources = sources: removeAttrs sources [ "__functor" "dorkfiles" ];
|
||||
source2drv = value: if isDerivation value.outPath then value.outPath else value;
|
||||
sources2drvs = sources: mapAttrs (_: source2drv) (getSources sources);
|
||||
in recurseIntoAttrs rec {
|
||||
in
|
||||
recurseIntoAttrs rec {
|
||||
local = sources2drvs sources;
|
||||
hexchen = sources2drvs (import sources.hexchen {}).sources;
|
||||
hexchen = sources2drvs (import sources.hexchen { }).sources;
|
||||
all = attrValues local ++ attrValues hexchen;
|
||||
allStr = toString all;
|
||||
};
|
||||
|
|
@ -26,11 +27,13 @@ let
|
|||
If only one exists, the path for that one is returned.
|
||||
Otherwise a module is generated which contains both import paths.
|
||||
*/
|
||||
xargNames = lib.unique (lib.folderList ./config ["trusted"] ++ lib.folderList ./config/trusted ["pkgs" "tf"]);
|
||||
xarg = lib.mapListToAttrs (folder: lib.nameValuePair folder (lib.domainMerge {
|
||||
xargNames = lib.unique (lib.folderList ./config [ "trusted" ] ++ lib.folderList ./config/trusted [ "pkgs" "tf" ]);
|
||||
xarg = lib.mapListToAttrs
|
||||
(folder: lib.nameValuePair folder (lib.domainMerge {
|
||||
inherit folder;
|
||||
folderPaths = [ (./config + "/${folder}") (./config/trusted + "/${folder}") ];
|
||||
})) xargNames;
|
||||
}))
|
||||
xargNames;
|
||||
|
||||
/*
|
||||
We provide the runners with this file this way. We also provide our nix args here.
|
||||
|
|
@ -53,7 +56,7 @@ let
|
|||
# This is where the meta config is evaluated.
|
||||
eval = lib.evalModules {
|
||||
modules = lib.singleton metaConfig
|
||||
++ lib.attrValues (removeAttrs xarg.targets ["common"])
|
||||
++ lib.attrValues (removeAttrs xarg.targets [ "common" ])
|
||||
++ lib.attrValues xarg.hosts
|
||||
++ lib.singleton ./config/modules/meta/default.nix;
|
||||
|
||||
|
|
@ -66,7 +69,7 @@ let
|
|||
# The evaluated meta config.
|
||||
inherit (eval) config;
|
||||
|
||||
/*
|
||||
/*
|
||||
Please note all specialArg generated specifications use the folder common to both import paths.
|
||||
Those import paths are as mentioned above next to `xargNames`.
|
||||
|
||||
|
|
@ -78,6 +81,7 @@ let
|
|||
* targets -> the specialArg generated from targets/
|
||||
* do not use common, it is tf-nix specific config ingested at line 66 of config/modules/meta/deploy.nix for every target.
|
||||
* services -> the specialArg generated from services/
|
||||
*/
|
||||
self = config // { inherit pkgs lib sourceCache sources; } // xarg;
|
||||
in self
|
||||
*/
|
||||
self = config // { inherit pkgs lib sourceCache sources; } // xarg;
|
||||
in
|
||||
self
|
||||
|
|
|
|||
|
|
@ -23,4 +23,5 @@ let
|
|||
];
|
||||
};
|
||||
};
|
||||
in pkgs
|
||||
in
|
||||
pkgs
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
{ }: let
|
||||
{}:
|
||||
let
|
||||
meta = import ./default.nix;
|
||||
config = meta;
|
||||
inherit (meta) pkgs;
|
||||
|
|
@ -58,7 +59,8 @@
|
|||
done
|
||||
cd $START_DIR
|
||||
'';
|
||||
in pkgs.mkShell {
|
||||
in
|
||||
pkgs.mkShell {
|
||||
nativeBuildInputs = with pkgs; [
|
||||
inetutils
|
||||
nf-update
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue