fix(home): Submodule opts weren't being detected correctly

This commit is contained in:
punkfairie 2024-11-16 23:29:38 -08:00
parent 910a7f1695
commit 4dd4d4a1cf
Signed by: punkfairie
GPG key ID: A509E8F77FB9D696
43 changed files with 89 additions and 176 deletions

View file

@ -1,42 +1,4 @@
{ lib, ... }: _: {
with lib;
rec {
## Create a module option with only an enable option.
## ```nix
## options = lib.mkEnableModule "module-name"
## ```
##
#@ String
mkEnableModule = name: {
marleyos."${name}".enable = mkEnableOption "${name}";
};
## Create a NixOS module option.
##
## ```nix
## lib.mkOpt nixpkgs.lib.types.str "My default" "Description of my option."
## ```
##
#@ Type -> Any -> String
mkOpt =
type: default: description:
mkOption {
inherit
type
default
description
;
};
## Create a boolean NixOS module option.
##
## ```nix
## lib.mkBoolOpt true "Description of my option."
## ```
##
#@ Type -> Any -> String
mkBoolOpt = mkOpt types.bool;
enabled = { enabled = {
## Quickly enable an option. ## Quickly enable an option.
## ##

View file

@ -5,14 +5,14 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule enabled; inherit (lib.marleyos) enabled;
cfg = config.marleyos.appearance.base; cfg = config.marleyos.appearance.base;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options.marleyos = mkEnableModule "appearance.base"; options.marleyos.appearance.base.enable = mkEnableOption "base";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -1,18 +1,17 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule enabled; inherit (lib.marleyos) enabled;
cfg = config.marleyos.appearance.gtk; cfg = config.marleyos.appearance.gtk;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options.marleyos = mkEnableModule "appearance.gtk"; options.marleyos.appearance.gtk.enable = mkEnableOption "gtk";
config = mkIf cfg.enable { config = mkIf cfg.enable {
gtk = { gtk = {

View file

@ -5,14 +5,13 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.appearance.qt; cfg = config.marleyos.appearance.qt;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options.marleyos = mkEnableModule "appearance.qt"; options.marleyos.appearance.qt.enable = mkEnableOption "qt";
config = mkIf cfg.enable { config = mkIf cfg.enable {
xdg.configFile = mkIf (colors.base == "rose-pine") { xdg.configFile = mkIf (colors.base == "rose-pine") {

View file

@ -6,8 +6,7 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.amfora; cfg = config.marleyos.programs.amfora;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
@ -19,7 +18,7 @@ let
themeFile = themeFiles."${colors.base}"; themeFile = themeFiles."${colors.base}";
in in
{ {
options.marleyos = mkEnableModule "programs.amfora"; options.marleyos.programs.amfora = mkEnableOption "amfora";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -5,14 +5,14 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule enabled; inherit (lib.marleyos) enabled;
cfg = config.marleyos.programs.bat; cfg = config.marleyos.programs.bat;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options.marleyos = mkEnableModule "programs.bat"; options.marleyos.programs.bat = mkEnableOption "bat";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.bat = { programs.bat = {

View file

@ -4,14 +4,14 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule enabled; inherit (lib.marleyos) enabled;
cfg = config.marleyos.programs.btop; cfg = config.marleyos.programs.btop;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options.marleyos = mkEnableModule "programs.btop"; options.marleyos.programs.btop = mkEnableOption "btop";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.btop = { programs.btop = {

View file

@ -4,14 +4,14 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule enabled; inherit (lib.marleyos) enabled;
cfg = config.marleyos.programs.cava; cfg = config.marleyos.programs.cava;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options.marleyos = mkEnableModule "programs.cava"; options.marleyos.programs.cava = mkEnableOption "cava";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.cava = { programs.cava = {

View file

@ -5,8 +5,7 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.cheat; cfg = config.marleyos.programs.cheat;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
@ -14,7 +13,7 @@ let
toYAML = (pkgs.formats.yaml { }).generate; toYAML = (pkgs.formats.yaml { }).generate;
in in
{ {
options.marleyos = mkEnableModule "programs.cheat"; options.marleyos.programs.cheat = mkEnableOption "cheat";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -5,13 +5,12 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.curl; cfg = config.marleyos.programs.curl;
in in
{ {
options.marleyos = mkEnableModule "programs.curl"; options.marleyos.programs.curl = mkEnableOption "curl";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -4,13 +4,12 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.eza; cfg = config.marleyos.programs.eza;
in in
{ {
options.marleyos = mkEnableModule "programs.eza"; options.marleyos.programs.eza = mkEnableOption "eza";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.eza = { programs.eza = {

View file

@ -5,13 +5,12 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.figlet; cfg = config.marleyos.programs.figlet;
in in
{ {
options.marleyos = mkEnableModule "programs.figlet"; options.marleyos.programs.figlet = mkEnableOption "figlet";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -5,14 +5,14 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule enabled; inherit (lib.marleyos) enabled;
cfg = config.marleyos.programs.fish; cfg = config.marleyos.programs.fish;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options.marleyos = mkEnableModule "programs.fish"; options.marleyos.programs.fish.enable = mkEnableOption "fish";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -4,8 +4,8 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule enabled; inherit (lib.marleyos) enabled;
cfg = config.marleyos.programs.fzf; cfg = config.marleyos.programs.fzf;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
@ -19,7 +19,7 @@ let
has-difft = config.programs.git.difftastic.enable; has-difft = config.programs.git.difftastic.enable;
in in
{ {
options.marleyos = mkEnableModule "programs.fzf"; options.marleyos.programs.fzf.enable = mkEnableOption "fzf";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.fzf = { programs.fzf = {

View file

@ -5,13 +5,12 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.gh; cfg = config.marleyos.programs.gh;
in in
{ {
options.marleyos = mkEnableModule "programs.gh"; options.marleyos.programs.gh.enable = mkEnableOption "gh";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.gh = { programs.gh = {

View file

@ -1,7 +1,6 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let

View file

@ -5,13 +5,12 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.git; cfg = config.marleyos.programs.git;
in in
{ {
options.marleyos = mkEnableModule "programs.git"; options.marleyos.programs.git.enable = mkEnableOption "git";
imports = [ imports = [
./aliases.nix ./aliases.nix

View file

@ -1,19 +1,17 @@
{ {
lib, lib,
config, config,
namespace,
pkgs, pkgs,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.glow; cfg = config.marleyos.programs.glow;
toYAML = (pkgs.formats.yaml { }).generate; toYAML = (pkgs.formats.yaml { }).generate;
in in
{ {
options.marleyos = mkEnableModule "programs.glow"; options.marleyos.programs.glow.enable = mkEnableOption "glow";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.gpg; cfg = config.marleyos.programs.gpg;
in in
{ {
options.marleyos = mkEnableModule "programs.gpg"; options.marleyos.programs.gpg.enable = mkEnableOption "gpg";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.gpg = { programs.gpg = {

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.hyfetch; cfg = config.marleyos.programs.hyfetch;
in in
{ {
options.marleyos = mkEnableModule "programs.hyfetch"; options.marleyos.programs.hyfetch.enable = mkEnableOption "hyfetch";
imports = [ imports = [
./neofetch.nix ./neofetch.nix

View file

@ -1,7 +1,6 @@
{ {
lib, lib,
config, config,
namespace,
pkgs, pkgs,
... ...
}: }:

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.journalctl; cfg = config.marleyos.programs.journalctl;
in in
{ {
options.marleyos = mkEnableModule "programs.journalctl"; options.marleyos.programs.journalctl.enable = mkEnableOption "journalctl";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.shellAbbrs = { home.shellAbbrs = {

View file

@ -1,18 +1,16 @@
{ {
lib, lib,
config, config,
namespace,
pkgs, pkgs,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.just; cfg = config.marleyos.programs.just;
in in
{ {
options.marleyos = mkEnableModule "programs.just"; options.marleyos.programs.just.enable = mkEnableOption "just";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -1,19 +1,17 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.lazygit; cfg = config.marleyos.programs.lazygit;
has-delta = config.programs.git.delta.enable; has-delta = config.programs.git.delta.enable;
has-difft = config.programs.git.difftastic.enable; has-difft = config.programs.git.difftastic.enable;
in in
{ {
options.marleyos = mkEnableModule "programs.lazygit"; options.marleyos.programs.lazygit.enable = mkEnableOption "lazygit";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.lazygit = { programs.lazygit = {

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.less; cfg = config.marleyos.programs.less;
in in
{ {
options.marleyos = mkEnableModule "programs.less"; options.marleyos.programs.less.enable = mkEnableOption "less";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.less.enable = true; programs.less.enable = true;

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.man; cfg = config.marleyos.programs.man;
in in
{ {
options.marleyos = mkEnableModule "programs.man"; options.marleyos.programs.man.enable = mkEnableOption "man";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.man.enable = true; programs.man.enable = true;

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.ncmpcpp; cfg = config.marleyos.programs.ncmpcpp;
in in
{ {
options.marleyos = mkEnableModule "programs.ncmpcpp"; options.marleyos.programs.ncmpcpp.enable = mkEnableOption "ncmpcpp";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.ncmpcpp.enable = true; programs.ncmpcpp.enable = true;

View file

@ -1,18 +1,16 @@
{ {
lib, lib,
config, config,
namespace,
pkgs, pkgs,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.neo; cfg = config.marleyos.programs.neo;
in in
{ {
options.marleyos = mkEnableModule "programs.neo"; options.marleyos.programs.neo.enable = mkEnableOption "neo";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.rbw; cfg = config.marleyos.programs.rbw;
in in
{ {
options.marleyos = mkEnableModule "programs.rbw"; options.marleyos.programs.rbw.enable = mkEnableOption "rbw";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.rbw = { programs.rbw = {

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.ripgrep; cfg = config.marleyos.programs.ripgrep;
in in
{ {
options.marleyos = mkEnableModule "programs.ripgrep"; options.marleyos.programs.ripgrep.enable = mkEnableOption "ripgrep";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.ripgrep.enable = true; programs.ripgrep.enable = true;

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.ssh; cfg = config.marleyos.programs.ssh;
in in
{ {
options.marleyos = mkEnableModule "programs.ssh"; options.marleyos.programs.ssh.enable = mkEnableOption "ssh";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.ssh = { programs.ssh = {

View file

@ -5,17 +5,18 @@
}: }:
let let
inherit (lib) inherit (lib)
mkEnableOption
mkIf mkIf
mkForce mkForce
concatStrings concatStrings
; ;
inherit (lib.marleyos) mkEnableModule enabled; inherit (lib.marleyos) enabled;
cfg = config.marleyos.programs.starship; cfg = config.marleyos.programs.starship;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options.marleyos = mkEnableModule "programs.starship"; options.marleyos.programs.starship.enable = mkEnableOption "starship";
imports = [ imports = [
./nerd-font-symbols.nix ./nerd-font-symbols.nix

View file

@ -1,7 +1,6 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.systemctl; cfg = config.marleyos.programs.systemctl;
in in
{ {
options.marleyos = mkEnableModule "programs.systemctl"; options.marleyos.programs.systemctl.enable = mkEnableOption "systemctl";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.shellAbbrs = { home.shellAbbrs = {

View file

@ -5,14 +5,13 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.tmux; cfg = config.marleyos.programs.tmux;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options.marleyos = mkEnableModule "programs.tmux"; options.marleyos.programs.tmux.enable = mkEnableOption "tmux";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.tmux = { programs.tmux = {

View file

@ -5,8 +5,7 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.wezterm; cfg = config.marleyos.programs.wezterm;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
@ -14,7 +13,7 @@ let
isGenericLinux = config.targets.genericLinux.enable; isGenericLinux = config.targets.genericLinux.enable;
in in
{ {
options.marleyos = mkEnableModule "programs.wezterm"; options.marleyos.programs.wezterm.enable = mkEnableOption "wezterm";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.wezterm = { programs.wezterm = {

View file

@ -1,18 +1,16 @@
{ {
lib, lib,
config, config,
namespace,
pkgs, pkgs,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.wget; cfg = config.marleyos.programs.wget;
in in
{ {
options.marleyos = mkEnableModule "programs.wget"; options.marleyos.programs.wget.enable = mkEnableOption "wget";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -4,14 +4,14 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule enabled; inherit (lib.marleyos) enabled;
cfg = config.marleyos.programs.zathura; cfg = config.marleyos.programs.zathura;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
in in
{ {
options = mkEnableModule "programs.zathura"; options.marleyos.programs.zathura.enable = mkEnableOption "zathura";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.zathura = { programs.zathura = {

View file

@ -1,17 +1,15 @@
{ {
lib, lib,
config, config,
namespace,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.programs.zoxide; cfg = config.marleyos.programs.zoxide;
in in
{ {
options.marleyos = mkEnableModule "programs.zoxide"; options.marleyos.programs.zoxide.enable = mkEnableOption "zoxide";
config = mkIf cfg.enable { config = mkIf cfg.enable {
programs.zoxide = { programs.zoxide = {

View file

@ -1,18 +1,16 @@
{ {
lib, lib,
config, config,
namespace,
pkgs, pkgs,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.services.clipboard; cfg = config.marleyos.services.clipboard;
in in
{ {
options.marleyos = mkEnableModule "services.clipboard"; options.marleyos.services.clipboard.enable = mkEnableOption "clipboard";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = with pkgs; [ home.packages = with pkgs; [

View file

@ -5,10 +5,11 @@
}: }:
let let
inherit (lib) inherit (lib)
mkEnableOption
mkIf mkIf
mkMerge mkMerge
; ;
inherit (lib.marleyos) mkEnableModule disabled; inherit (lib.marleyos) disabled;
cfg = config.marleyos.services.dunst; cfg = config.marleyos.services.dunst;
inherit (config.marleyos.theme) colors; inherit (config.marleyos.theme) colors;
@ -16,7 +17,7 @@ let
isRosePine = colors.base == "rose-pine"; isRosePine = colors.base == "rose-pine";
in in
{ {
options.marleyos = mkEnableModule "services.dunst"; options.marleyos.services.dunst.enable = mkEnableOption "dunst";
config = mkIf cfg.enable { config = mkIf cfg.enable {
services.dunst = { services.dunst = {

View file

@ -1,18 +1,16 @@
{ {
lib, lib,
config, config,
namespace,
pkgs, pkgs,
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.services.syncthing; cfg = config.marleyos.services.syncthing;
in in
{ {
options.marleyos = mkEnableModule "services.syncthing"; options.marleyos.services.syncthing.enable = mkEnableOption "syncthing";
config = mkIf cfg.enable { config = mkIf cfg.enable {
home.packages = [ home.packages = [

View file

@ -4,13 +4,12 @@
... ...
}: }:
let let
inherit (lib) mkIf; inherit (lib) mkEnableOption mkIf;
inherit (lib.marleyos) mkEnableModule;
cfg = config.marleyos.xorg.xsession; cfg = config.marleyos.xorg.xsession;
in in
{ {
options.marleyos = mkEnableModule "xorg.xsession"; options.marleyos.xorg.xsession.enable = mkEnableOption "xsession";
config = mkIf cfg.enable { config = mkIf cfg.enable {
xsession = { xsession = {