Formatting

This commit is contained in:
Nox Sluijtman 2025-04-18 09:37:57 +02:00
parent ae65065d5c
commit 3ca8c5e218
Signed by: Egg
SSH key fingerprint: SHA256:2sG9X3C7Xvq2svGumz1/k7cm8l4G9+qAtAeugqB4J9M
9 changed files with 156 additions and 108 deletions

View file

@ -1,7 +1,14 @@
{ lib, config, pkgs, ... }: {
lib,
config,
pkgs,
...
}:
with lib; with lib;
let cfg = config.voidconf.fcitx5; let
in { cfg = config.voidconf.fcitx5;
in
{
options.voidconf.fcitx5 = { options.voidconf.fcitx5 = {
enable = mkEnableOption "Enables fcitx5 input method engine and mozc en anthy methods"; enable = mkEnableOption "Enables fcitx5 input method engine and mozc en anthy methods";
}; };

View file

@ -1,8 +1,10 @@
{ lib, config, ... }: { lib, config, ... }:
with lib; with lib;
let cfg = config.voidconf.graphics; let
in { cfg = config.voidconf.graphics;
options.voidconf.graphics ={ in
{
options.voidconf.graphics = {
defaultSettings.enable = mkEnableOption "Enables some basic graphical settings"; defaultSettings.enable = mkEnableOption "Enables some basic graphical settings";
nvidia = { nvidia = {
enable = mkEnableOption "Enables Nvidia settings"; enable = mkEnableOption "Enables Nvidia settings";
@ -25,6 +27,6 @@ in {
nvidiaSettings = cfg.nvidia.proprietaryDrivers; nvidiaSettings = cfg.nvidia.proprietaryDrivers;
}; };
}; };
services.xserver.videoDrivers = mkIf cfg.nvidia.proprietaryDrivers ["nvidia"]; services.xserver.videoDrivers = mkIf cfg.nvidia.proprietaryDrivers [ "nvidia" ];
}; };
} }

View file

@ -1,7 +1,9 @@
{ lib, config, ... }: { lib, config, ... }:
with lib; with lib;
let cfg = config.voidconf.kernelTweaks; let
in { cfg = config.voidconf.kernelTweaks;
in
{
options.voidconf.kernelTweaks = { options.voidconf.kernelTweaks = {
enable = mkEnableOption "Enables kernel tweaks"; enable = mkEnableOption "Enables kernel tweaks";
}; };

View file

@ -1,7 +1,9 @@
{ lib, config, ... }: { lib, config, ... }:
with lib; with lib;
let cfg = config.voidconf.nixSettings; let
in { cfg = config.voidconf.nixSettings;
in
{
options.voidconf.nixSettings = { options.voidconf.nixSettings = {
gc = { gc = {
automatic = mkOption { automatic = mkOption {
@ -36,7 +38,10 @@ in {
automatic = cfg.gc.automatic; automatic = cfg.gc.automatic;
dates = cfg.gc.dates; dates = cfg.gc.dates;
}; };
settings.experimental-features = [ "flakes" "nix-command" ]; settings.experimental-features = [
"flakes"
"nix-command"
];
}; };
}; };
} }

View file

@ -1,7 +1,9 @@
{ lib, config, ... }: { lib, config, ... }:
with lib; with lib;
let cfg = config.voidconf.prometheus; let
in { cfg = config.voidconf.prometheus;
in
{
options.voidconf.prometheus = { options.voidconf.prometheus = {
enable = mkEnableOption "Enable prometheus node"; enable = mkEnableOption "Enable prometheus node";
}; };
@ -10,7 +12,10 @@ in {
exporters = { exporters = {
node = { node = {
enable = true; enable = true;
enabledCollectors = [ "systemd" "cpu" ]; enabledCollectors = [
"systemd"
"cpu"
];
port = 9002; port = 9002;
}; };
}; };

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }: {
config,
lib,
pkgs,
...
}:
with lib; with lib;
let cfg = config.voidconf.services; let
in { cfg = config.voidconf.services;
in
{
options.voidconf.services = { options.voidconf.services = {
flatpak = { flatpak = {
@ -26,7 +33,7 @@ in {
}; };
config = { config = {
# flatpak # flatpak
xdg.portal = mkIf cfg.flatpak.enable { xdg.portal = mkIf cfg.flatpak.enable {
enable = true; enable = true;
@ -35,7 +42,7 @@ in {
config.common.default = "*"; config.common.default = "*";
}; };
# ssh # ssh agent
programs.ssh = mkIf cfg.ssh.enable { programs.ssh = mkIf cfg.ssh.enable {
startAgent = true; startAgent = true;
@ -43,11 +50,11 @@ in {
services = { services = {
# flatpak # flatpak
flatpak.enable = cfg.flatpak.enable; flatpak.enable = cfg.flatpak.enable;
# yggdrasil # yggdrasil
yggdrasil = mkIf cfg.yggdrasil.enable { yggdrasil = mkIf cfg.yggdrasil.enable {
enable = true; enable = true;
@ -74,6 +81,9 @@ in {
]; ];
}; };
}; };
# ssh daemon
openssh = mkIf cfg.ssh.enable { openssh = mkIf cfg.ssh.enable {
enable = true; enable = true;
settings = { settings = {
@ -82,7 +92,7 @@ in {
}; };
}; };
# i2p container # i2p container
containers.i2pd-container = mkIf cfg.i2p.enable { containers.i2pd-container = mkIf cfg.i2p.enable {
autoStart = cfg.i2p.autoStart; autoStart = cfg.i2p.autoStart;

View file

@ -1,7 +1,14 @@
{ config, lib, pkgs, ... }: {
config,
lib,
pkgs,
...
}:
with lib; with lib;
let cfg = config.voidconf.vim; let
in { cfg = config.voidconf.vim;
in
{
options.voidconf.vim = { options.voidconf.vim = {
enable = mkEnableOption "Enables opinionated vim configuration"; enable = mkEnableOption "Enables opinionated vim configuration";
enableNvim = mkEnableOption "Enables neovim and alias"; enableNvim = mkEnableOption "Enables neovim and alias";
@ -31,7 +38,7 @@ in {
vimrcConfig = { vimrcConfig = {
packages.myplugs = with pkgs.vimPlugins; { packages.myplugs = with pkgs.vimPlugins; {
start = [ vim-nix ]; start = [ vim-nix ];
opt = []; opt = [ ];
}; };
customRC = '' customRC = ''
syntax on syntax on

View file

@ -1,7 +1,9 @@
{ config, lib, ... }: { config, lib, ... }:
with lib; with lib;
let cfg = config.voidconf.xconfig; let
in { cfg = config.voidconf.xconfig;
in
{
options.voidconf.xconfig = { options.voidconf.xconfig = {
enable = mkEnableOption "Enables opinionated xorg config"; enable = mkEnableOption "Enables opinionated xorg config";
@ -12,7 +14,10 @@ in {
enableProperConfig = mkEnableOption "Enable the touchpad settings"; enableProperConfig = mkEnableOption "Enable the touchpad settings";
accelProfile = mkOption { accelProfile = mkOption {
type = types.enum [ "flat" "adaptive" ]; type = types.enum [
"flat"
"adaptive"
];
default = "adaptive"; default = "adaptive";
example = "flat"; example = "flat";
description = '' description = ''
@ -23,7 +28,10 @@ in {
}; };
mouse.accelProfile = mkOption { mouse.accelProfile = mkOption {
type = types.enum [ "flat" "adaptive" ]; type = types.enum [
"flat"
"adaptive"
];
default = "flat"; default = "flat";
example = "adaptive"; example = "adaptive";
description = '' description = ''

View file

@ -1,7 +1,9 @@
{ config, lib, ... }: { config, lib, ... }:
with lib; with lib;
let cfg = config.voidconf.zsh; let
in { cfg = config.voidconf.zsh;
in
{
options.voidconf.zsh = { options.voidconf.zsh = {
enable = mkEnableOption "Enables opinionated zsh configuration"; enable = mkEnableOption "Enables opinionated zsh configuration";
skim.enable = mkEnableOption "Enables skim support for shell history"; skim.enable = mkEnableOption "Enables skim support for shell history";