refactor: updated all modules to not use global with syntax for lib and lib.${namespace}

This commit is contained in:
Ceferino Patino 2025-06-08 23:10:08 -05:00
commit c3b37cf694
Signed by: c4patino
SSH key fingerprint: SHA256:Wu+cU1t+7zVT9wzew/4meNmeulo66NzMqc22MdDBgXI
117 changed files with 607 additions and 714 deletions

View file

@ -2,9 +2,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; {
}: let
inherit (lib.${namespace}) enabled;
in {
${namespace} = {
bundles = {
common = enabled;

View file

@ -2,9 +2,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; {
}: let
inherit (lib.${namespace}) enabled;
in {
imports = [./stylix.nix];
${namespace} = {

View file

@ -2,9 +2,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; {
}: let
inherit (lib.${namespace}) enabled;
in {
imports = [./stylix.nix];
${namespace} = {

View file

@ -2,9 +2,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; {
}: let
inherit (lib.${namespace}) enabled;
in {
${namespace} = {
bundles = {
common = enabled;

View file

@ -168,7 +168,6 @@ with lib; rec {
## @param pathStr dot-separated list for the nested attribute to retrieve
## @param attrs attribute list for getting the keys
## @return attribute value if found; otherwise null
getIn = pathStr: attrs: let
path = splitString "." pathStr;
go = attrs: p:

View file

@ -6,16 +6,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.bundles.common";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "common bundle";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "common bundle";
};
config = mkIf cfg.enable {
${namespace} = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.bundles.desktop.applications";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "desktop application bundle";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "desktop application bundle";
};
config = mkIf cfg.enable {
${namespace} = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.bundles.desktop";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "desktop environment bundle";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "desktop environment bundle";
};
config = mkIf cfg.enable {
${namespace} = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.bundles.development";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "development bundle";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "development bundle";
};
config = mkIf cfg.enable {
${namespace} = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.bundles.shell";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "shell utility bundle";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "shell utility bundle";
};
config = mkIf cfg.enable {
${namespace} = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.access.crypt";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "git-crypt";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "git-crypt";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [git-crypt];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.access.lastpass";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "lastpass-cli";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "lastpass-cli";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [lastpass-cli];

View file

@ -5,9 +5,9 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.access.sops";
cfg = getAttrByNamespace config base;
in {
@ -15,10 +15,9 @@ in {
inputs.sops-nix.homeManagerModules.sops
];
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "sops-nix";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "sops-nix";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [sops];

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.access.ssh";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "ssh";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "ssh";
};
config = mkIf cfg.enable {
programs.ssh = {

View file

@ -4,16 +4,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.dev.direnv";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "direnv";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "direnv";
};
config = mkIf cfg.enable {
programs.direnv = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.cli.dev.git";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "git";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "git";
};
config = mkIf cfg.enable {
programs.git = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.dev.lazygit";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "lazygit";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "lazygit";
};
config = mkIf cfg.enable {
programs.lazygit.enable = true;

View file

@ -5,16 +5,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.dev.leetcode";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "leetcode";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "leetcode";
};
config = mkIf cfg.enable {
home = {

View file

@ -5,16 +5,15 @@
namespace,
system,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.dev.neovim";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "neovim";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "neovim";
};
config = mkIf cfg.enable {
home = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.dev.zoxide";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "zoxide";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "zoxide";
};
config = mkIf cfg.enable {
programs.zoxide = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.dev.zsh";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "zsh";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "zsh";
};
config = mkIf cfg.enable {
home = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.media.bat";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "bat";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "bat";
};
config = mkIf cfg.enable {
programs.bat = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.media.cava";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "cava";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "cava";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [cava];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.media.grim";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "grim";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "grim";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [grim];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.media.pandoc";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "pandoc";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "pandoc";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [pandoc];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.media.slurp";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "grim";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "grim";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [slurp];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.media.spotify";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "spotify";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "spotify";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [spotify-player];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.cli.media.yazi";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "yazi";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "yazi";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.metrics.btm";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "btm";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "btm";
};
config = mkIf cfg.enable {
programs.bottom = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.metrics.hyperfine";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "hyperfine";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "hyperfine";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [hyperfine];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.metrics.nvtop";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "nvtop";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "nvtop";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [nvtopPackages.nvidia];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.cli.scripts";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "custom shell scripts";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "custom shell scripts";
};
config = mkIf cfg.enable {
home.packages = [

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.browsers.vivaldi";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Vivaldi";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Vivaldi";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [vivaldi];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.editors.jetbrains.android-studio";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Android Studio";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Android Studio";
};
config = mkIf cfg.enable {
home = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.editors.jetbrains.clion";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "CLion";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "CLion";
};
config = mkIf cfg.enable {
home = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.editors.jetbrains.idea";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Idea";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Idea";
};
config = mkIf cfg.enable {
home = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.editors.jetbrains.pycharm";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "PyCharm";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "PyCharm";
};
config = mkIf cfg.enable {
home = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.editors.jetbrains.rider";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Rider";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Rider";
};
config = mkIf cfg.enable {
home = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.desktop.apps.editors.vscode";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "VSCode";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "VSCode";
};
config = mkIf cfg.enable {
programs.vscode = enabled;

View file

@ -2,17 +2,17 @@
config,
lib,
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.games.prismlauncher";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "PrismLauncher";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "PrismLauncher";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [prismlauncher];

View file

@ -6,9 +6,9 @@
pkgs,
system,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption getExe;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.launchers.anyrun";
cfg = getAttrByNamespace config base;
@ -17,10 +17,9 @@ with lib.${namespace}; let
${getExe pkgs.sassc} -t expanded '${source}' > $out/${name}.css
''}/${name}.css";
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Anyrun";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Anyrun";
};
config = mkIf cfg.enable {
programs.anyrun = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.media.fiji";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Fiji";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Fiji";
};
config = mkIf cfg.enable {
home = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.media.libreoffice";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "LibreOffice";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "LibreOffice";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.media.obsidian";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Obsidian";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Obsidian";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [obsidian];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.media.spotify";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Spotify";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Spotify";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [spotify];

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.media.zathura";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Zathura";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Zathura";
};
config = mkIf cfg.enable {
programs.zathura = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.media.zotero";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Zotero";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Zotero";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [zotero];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.sms.discord";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Discord";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Discord";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [webcord-vencord];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.sms.slack";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Slack";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Slack";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [slack];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.sms.zoom";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Zoom";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Zoom";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [zoom-us];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.terminals.kitty";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Kitty";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Kitty";
};
config = {
home.packages = with pkgs; [kitty.terminfo];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.tools.mongodb-compass";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "MongoDB Compass";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "MongoDB Compass";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [mongodb-compass];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.tools.obs";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "OBS Studio";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "OBS Studio";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [obs-studio];

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.tools.postman";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Postman";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Postman";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [postman];

View file

@ -5,16 +5,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.env.eww";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "eww";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "eww";
};
config = mkIf cfg.enable {
home = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.env.gtk";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "gtk";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "gtk";
};
config = mkIf cfg.enable {
qt = {

View file

@ -1,24 +0,0 @@
{
pkgs,
config,
lib,
...
}: let
inherit (lib) mkIf;
cfg = config.hyprland;
in {
config = mkIf cfg.enable {
qt = {
enable = true;
platformTheme.name = "gtk";
};
gtk = {
enable = true;
theme = {
package = pkgs.adw-gtk3;
name = "adw-gtk3";
};
};
};
}

View file

@ -4,9 +4,9 @@
namespace,
pkgs,
...
} @ args:
with lib;
with lib.${namespace}; let
} @ args: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.env.hyprland";
cfg = getAttrByNamespace config base;
in {
@ -16,10 +16,9 @@ in {
(import ./rules.nix args)
];
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Hyprland";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Hyprland";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [hyprpicker hyprpaper];

View file

@ -4,9 +4,9 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf;
inherit (lib.${namespace}) getAttrByNamespace;
base = "${namespace}.desktop.env.hyprland";
cfg = getAttrByNamespace config base;
in {

View file

@ -3,9 +3,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf;
inherit (lib.${namespace}) getAttrByNamespace;
base = "${namespace}.desktop.env.hyprland";
cfg = getAttrByNamespace config base;
in {

View file

@ -3,9 +3,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf;
inherit (lib.${namespace}) getAttrByNamespace;
base = "${namespace}.desktop.env.hyprland";
cfg = getAttrByNamespace config base;
in {

View file

@ -5,9 +5,9 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.services.hyprpaper";
cfg = getAttrByNamespace config base;
@ -23,10 +23,9 @@ with lib.${namespace}; let
${pkgs.hyprland}/bin/hyprctl hyprpaper reload ,"$WALLPAPER"
'';
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "hyprpaper";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "hyprpaper";
};
config = mkIf cfg.enable {
services.hyprpaper = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.services.mako";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Mako";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Mako";
};
config = mkIf cfg.enable {
services.mako = {

View file

@ -5,16 +5,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.services.variety";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "variety";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "variety";
};
config = mkIf cfg.enable {
home = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.services.wl-clipboard";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "wl-clipboard";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "wl-clipboard";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [

View file

@ -4,9 +4,9 @@
namespace,
pkgs,
...
} @ args:
with lib;
with lib.${namespace}; let
} @ args: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.bundles.common";
cfg = getAttrByNamespace config base;
in {
@ -15,10 +15,9 @@ in {
(import ./users.nix args)
];
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "common bundle";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "common bundle";
};
config = mkIf cfg.enable {
${namespace} = {

View file

@ -3,9 +3,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf;
inherit (lib.${namespace}) getAttrByNamespace;
base = "${namespace}.bundles.common";
cfg = getAttrByNamespace config base;
in {

View file

@ -8,6 +8,8 @@
}:
with lib;
with lib.${namespace}; let
inherit (lib) mkIf;
inherit (lib.${namespace}) getAttrByNamespace;
inherit (config.networking) hostName;
base = "${namespace}.bundles.common";
cfg = getAttrByNamespace config base;

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.bundles.desktop";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "desktop environment bundle";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "desktop environment bundle";
};
config = mkIf cfg.enable {
${namespace} = {

View file

@ -3,10 +3,11 @@
inputs,
lib,
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) types mkIf mkEnableOption mkOption mapAttrs mapAttrsToList flatten;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.games.minecraft";
cfg = getAttrByNamespace config base;
in {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.apps.games.steam";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Steam";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Steam";
};
config = mkIf cfg.enable {
programs.steam = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace enabled;
base = "${namespace}.desktop.apps.teamviewer";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Teamviewer";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Teamviewer";
};
config = mkIf cfg.enable {
environment.systemPackages = with pkgs; [teamviewer];

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.env.gdm";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "gdm";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "gdm";
};
config = mkIf cfg.enable {
services.xserver.displayManager.gdm = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.env.hyprland";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "hyprland";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "hyprland";
};
config = mkIf cfg.enable {
programs.hyprland = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.desktop.env.x11";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "X11";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "X11";
};
config = mkIf cfg.enable {
services.xserver = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.hardware.audio";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "audio";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "audio";
};
config = mkIf cfg.enable {
security.rtkit.enable = true;

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.hardware.battery";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "battery";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "battery";
};
config = mkIf cfg.enable {
environment.systemPackages = with pkgs; [acpi];

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.hardware.bluetooth";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "bluetooth";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "bluetooth";
};
config = mkIf cfg.enable {
services.blueman.enable = true;

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.hardware.bootloader";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "bootloader";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "bootloader";
};
config = mkIf cfg.enable {
boot.loader.grub = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.hardware.nvidia";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "nvidia";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "nvidia";
};
config = mkIf cfg.enable {
hardware.graphics = {

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.hardware.printing";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "printing";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "printing";
};
config = mkIf cfg.enable {
services.printing.enable = true;

View file

@ -4,9 +4,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.hardware.xremap";
cfg = getAttrByNamespace config base;
in {
@ -14,10 +14,9 @@ in {
inputs.xremap.nixosModules.default
];
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "xremap";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "xremap";
};
config = {
services.xremap = {

View file

@ -4,9 +4,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption filterAttrs attrNames head mkForce;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace resolveHostIP readJsonOrEmpty getIn;
inherit (config.networking) hostName;
base = "${namespace}.services.apps.forgejo";
cfg = getAttrByNamespace config base;
@ -21,10 +21,9 @@ with lib.${namespace}; let
port = 5300;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "forgejo";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "forgejo";
};
config = mkIf cfg.enable {
services.forgejo = {

View file

@ -3,9 +3,9 @@
lib,
namespace,
...
} @ args:
with lib;
with lib.${namespace}; let
} @ args: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.services.apps.glance";
cfg = getAttrByNamespace config base;
@ -15,10 +15,9 @@ in {
(import ./layout.nix args)
];
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "glance";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "glance";
};
config = mkIf cfg.enable {
services.glance = {

View file

@ -5,19 +5,18 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.services.apps.rustypaste";
cfg = getAttrByNamespace config base;
userCfg = config.users.users;
port = 5100;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "rustypaste";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "rustypaste";
};
config = mkIf cfg.enable {
environment.systemPackages = with pkgs; [rustypaste-cli];

View file

@ -5,9 +5,9 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption filterAttrs attrNames head elem;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace readJsonOrEmpty getIn resolveHostIP;
base = "${namespace}.services.apps.vaultwarden";
cfg = getAttrByNamespace config base;
pgCfg = getAttrByNamespace config "${namespace}.services.storage.postgresql";
@ -15,10 +15,9 @@ with lib.${namespace}; let
port = 5400;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "vaultwarden";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "vaultwarden";
};
config = mkIf cfg.enable {
services.vaultwarden = {

View file

@ -4,9 +4,9 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) types mkIf mkEnableOption mkOption genList mapAttrs optional attrValues concatLists listToAttrs;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
inherit (config.sops) secrets;
inherit (config.networking) hostName;
base = "${namespace}.services.ci.gitea-runner";

View file

@ -4,9 +4,9 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) types mkEnableOption mkOption mkIf optional mapAttrs';
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
inherit (config.networking) hostName;
inherit (config.sops) secrets;
base = "${namespace}.services.ci.github-runner";

View file

@ -2,18 +2,18 @@
config,
lib,
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.services.ci.pm2";
cfg = getAttrByNamespace config base;
userCfg = config.users.users;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "pm2";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "pm2";
};
config = mkIf cfg.enable {
environment.systemPackages = with pkgs; [pm2];

View file

@ -4,9 +4,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) types mkEnableOption mkOption mkIf groupBy mapAttrsToList attrNames mapAttrs concatStringsSep flatten;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace resolveHostIP;
inherit (config.networking) hostName;
base = "${namespace}.services.ci.slurm";
cfg = getAttrByNamespace config base;

View file

@ -5,9 +5,9 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption attrNames filterAttrs elem head;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace resolveHostIP readJsonOrEmpty getIn;
base = "${namespace}.services.metrics.grafana";
cfg = getAttrByNamespace config base;
pgCfg = getAttrByNamespace config "${namespace}.services.storage.postgresql";
@ -15,10 +15,9 @@ with lib.${namespace}; let
port = 5500;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Grafana";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Grafana";
};
config = mkIf cfg.enable {
services.grafana = {

View file

@ -6,15 +6,16 @@
}:
with lib;
with lib.${namespace}; let
inherit (lib) mkIf;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.services.metrics.ntfy";
cfg = getAttrByNamespace config base;
port = 5201;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "ntfy";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "ntfy";
};
config = mkIf cfg.enable {
services.ntfy-sh = {

View file

@ -4,19 +4,18 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption mkForce;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
inherit (config.users) users;
base = "${namespace}.services.metrics.uptime-kuma";
cfg = getAttrByNamespace config base;
port = 5200;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "uptime-kuma";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "uptime-kuma";
};
config = mkIf cfg.enable {
services.uptime-kuma = {

View file

@ -4,19 +4,18 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption mapAttrsToList listToAttrs;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace resolveHostIP;
base = "${namespace}.services.networking.blocky";
cfg = getAttrByNamespace config base;
networkCfg = getAttrByNamespace config "${namespace}.services.networking";
port = 53;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "blocky";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "blocky";
};
config = mkIf cfg.enable {
services.blocky = {

View file

@ -3,9 +3,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) types mkOption optional optionalString concatStringsSep;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace resolveHostIP;
base = "${namespace}.services.networking";
cfg = getAttrByNamespace config base;
dnsCfg = getAttrByNamespace config "${base}.unbound";

View file

@ -4,9 +4,9 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption mapAttrsToList listToAttrs replaceStrings mkMerge concatStringsSep filterAttrs;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace readJsonOrEmpty getIn;
inherit (config.networking) hostName;
base = "${namespace}.services.networking.httpd";
cfg = getAttrByNamespace config base;
@ -65,10 +65,9 @@ with lib.${namespace}; let
// sslConfig;
};
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Apache HTTPD";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Apache HTTPD";
};
config = mkIf cfg.enable {
services.httpd = {

View file

@ -4,16 +4,15 @@
namespace,
pkgs,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkEnableOption mkIf;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.services.networking.network-manager";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "network-manager";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "network-manager";
};
config = mkIf cfg.enable {
environment.systemPackages = with pkgs; [networkmanagerapplet];

View file

@ -3,16 +3,15 @@
lib,
namespace,
...
}:
with lib;
with lib.${namespace}; let
}: let
inherit (lib) mkIf mkEnableOption;
inherit (lib.${namespace}) getAttrByNamespace mkOptionsWithNamespace;
base = "${namespace}.services.networking.tailscale";
cfg = getAttrByNamespace config base;
in {
options = with types;
mkOptionsWithNamespace base {
enable = mkEnableOption "Tailscale";
};
options = mkOptionsWithNamespace base {
enable = mkEnableOption "Tailscale";
};
config = mkIf cfg.enable {
services.tailscale.enable = true;

Some files were not shown because too many files have changed in this diff Show more