summaryrefslogtreecommitdiff
path: root/common/modules/matugen/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'common/modules/matugen/default.nix')
-rw-r--r--common/modules/matugen/default.nix129
1 files changed, 10 insertions, 119 deletions
diff --git a/common/modules/matugen/default.nix b/common/modules/matugen/default.nix
index a9aaaae..6bf73a2 100644
--- a/common/modules/matugen/default.nix
+++ b/common/modules/matugen/default.nix
@@ -13,12 +13,12 @@
}:
let
cfg = config.${moduleNameSpace}.matugen;
- link_zen = pkgs.writeShellScript "link_zen" ''
- export PROFILE_DIR=$(find ~/.config/zen/ -maxdepth 1 -type d -name "*.Default Profile" | head -n 1)
- mkdir -p "$PROFILE_DIR/chrome"
- ln -sf ~/.cache/wallust/userChrome.css "$PROFILE_DIR/chrome/userChrome.css"
- ln -sf ~/.config/userContent.css "$PROFILE_DIR/chrome/userContent.css"
- '';
+ # link_zen = pkgs.writeShellScript "link_zen" ''
+ # export PROFILE_DIR=$(find ~/.config/zen/ -maxdepth 1 -type d -name "*.Default Profile" | head -n 1)
+ # mkdir -p "$PROFILE_DIR/chrome"
+ # ln -sf ~/.cache/wallust/userChrome.css "$PROFILE_DIR/chrome/userChrome.css"
+ # ln -sf ~/.config/userContent.css "$PROFILE_DIR/chrome/userContent.css"
+ # '';
update_gtkcolors = pkgs.writeShellScript "update_gtkcolors" ''
dconf write /org/gnome/desktop/interface/color-scheme "'prefer-light'"
sleep 0.1
@@ -36,71 +36,12 @@ in
config = lib.mkIf cfg.enable (
lib.optionalAttrs homeManager {
- programs.wallust = {
- enable = true;
- settings = {
- backend = "fastresize";
- color_space = "salience";
- check_contrast = true;
- templates = {
- foot = lib.mkIf config.beeMods.terminal.foot {
- template = "foot-colors.ini";
- target = "~/.config/foot/colors.ini";
- };
- alacritty = lib.mkIf config.beeMods.terminal.alacritty {
- template = "alacritty-colors.toml";
- target = "~/.config/alacritty/colors.toml";
- };
- ghostty = lib.mkIf config.beeMods.terminal.ghostty {
- template = "ghostty-colors.conf";
- target = "~/.config/ghostty/themes/matugen";
- };
- zen = {
- template = "userChrome.css";
- target = "~/.cache/wallust/userChrome.css";
- };
- xresources = lib.mkIf (config.beeMods.x11.dwm.enable || config.beeMods.x11.bspwm.enable) {
- template = "colors-xresources";
- target = "~/.config/x11/matugen.Xresources";
- };
- sequences =
- lib.mkIf (config.beeMods.terminal.default == "foot" || config.beeMods.terminal.default == "ghostty")
- {
- template = "sequences";
- target = "~/.config/sequences";
- };
- };
- };
- };
-
- home.packages = with pkgs; [
- matugen
- ];
-
xdg.configFile = {
"matugen/config.toml" = {
text =
# toml
''
[config]
- ${lib.optionalString config.beeMods.terminal.alacritty ''
- [templates.alacritty]
- input_path = '~/.config/matugen/templates/alacritty-colors.toml'
- output_path = '~/.config/wallust/templates/alacritty-colors.toml'
- ''}
-
- ${lib.optionalString config.beeMods.terminal.foot ''
- [templates.foot]
- input_path = '~/.config/matugen/templates/foot-colors.ini'
- output_path = '~/.config/wallust/templates/foot-colors.ini'
- ''}
-
- ${lib.optionalString config.beeMods.terminal.ghostty ''
- [templates.ghostty]
- input_path = '~/.config/matugen/templates/ghostty.conf'
- output_path = '~/.config/wallust/templates/ghostty-colors.conf'
- ''}
-
${lib.optionalString config.programs.zathura.enable ''
[templates.zathura]
input_path = '~/.config/matugen/templates/zathura.toml'
@@ -108,12 +49,6 @@ in
''}
${lib.optionalString config.beeMods.mango.enable ''
- [templates.swaylock]
- input_path = '~/.config/matugen/templates/swaylock-colors'
- output_path = '~/.config/swaylock/swaylock-colors'
- ''}
-
- ${lib.optionalString config.beeMods.mango.enable ''
[templates.mango]
input_path = '~/.config/matugen/templates/mango.conf'
output_path = '~/.config/mango/mango-colors.conf'
@@ -132,10 +67,10 @@ in
output_path = '~/.config/yazi/theme.toml'
''}
- ${lib.optionalString (config.beeMods.x11.dwm.enable || config.beeMods.x11.bspwm.enable) ''
+ ${lib.optionalString (config.beeMods.dwm.enable) ''
[templates.Xresources]
input_path = "~/.config/matugen/templates/colors-xresources"
- output_path = "~/.config/wallust/templates/colors-xresources"
+ output_path = "~/.config/x11/matugen.Xresources"
''}
${lib.optionalString config.programs.vesktop.enable ''
@@ -144,13 +79,6 @@ in
output_path = "~/.config/vesktop/themes/system24.css"
''}
- ${lib.optionalString config.beeMods.mango.waybar ''
- [templates.waybar]
- input_path = "~/.config/matugen/templates/waybar.css"
- output_path = "~/.config/waybar/colors.css"
- # post_hook = "pkill -SIGUSR2 waybar"
- ''}
-
${lib.optionalString config.services.dunst.enable ''
[templates.dunst]
input_path = '~/.config/matugen/templates/dunstrc'
@@ -158,23 +86,6 @@ in
post_hook = "dunstctl reload"
''}
- ${lib.optionalString config.programs.rofi.enable ''
- [templates.rofi]
- input_path = '~/.config/matugen/templates/rofi-colors.rasi'
- output_path = '~/.config/rofi/shared/colors.rasi'
- ''}
-
- ${lib.optionalString config.gtk.enable ''
- [templates.gtk3]
- input_path = '~/.config/matugen/templates/colors.css'
- output_path = '~/.config/gtk-3.0/colors.css'
-
- [templates.gtk4]
- input_path = '~/.config/matugen/templates/colors.css'
- output_path = '~/.config/gtk-4.0/colors.css'
- # post_hook = "${update_gtkcolors}"
- ''}
-
${lib.optionalString config.beeMods.beeVim.enable ''
[templates.neovim]
input_path = "~/.config/matugen/templates/neovim.json"
@@ -186,30 +97,10 @@ in
''
[templates.sequences]
input_path = '~/.config/matugen/templates/sequences'
- output_path = '~/.config/wallust/templates/sequences'
+ output_path = '~/.config/sequences'
+ post_hook = "sh '${config.home.homeDirectory}/.config/sequences'"
''
}
-
- ${lib.optionalString config.beeMods.x11.bspwm.enable ''
- [templates.bspwm]
- input_path = "~/.config/matugen/templates/bspwm-colors"
- output_path = "~/.config/bspwm/colors"
- post_hook = "bspc wm -r"
- ''}
-
- [templates.zed]
- input_path = '~/.config/matugen/templates/zed.json'
- output_path = '~/.config/zed/themes/matugen.json'
-
- [templates.zen]
- input_path = '~/.config/matugen/templates/zen.css'
- output_path = '~/.config/wallust/templates/userChrome.css'
- post_hook = "${link_zen}"
-
- [templates.zen-userContent]
- input_path = '~/.config/matugen/templates/zen-usercontent.css'
- output_path = '~/.config/userContent.css'
- post_hook = "${link_zen}"
'';
};
};