From fa44f9863bd83e319add5c07fcedd136dc5552bd Mon Sep 17 00:00:00 2001 From: "info@data-pro.nu" Date: Wed, 25 Mar 2026 20:19:35 +0000 Subject: [PATCH] Regenerated --- Droidnix/Prompt | 141 +++--------------- Droidnix/README.org | 39 +++++ .../modules/traveldroid/system/bluetooth.nix | 35 +++++ 3 files changed, 91 insertions(+), 124 deletions(-) create mode 100644 Droidnix/generated/modules/traveldroid/system/bluetooth.nix diff --git a/Droidnix/Prompt b/Droidnix/Prompt index d4b717872..4c99c3b87 100644 --- a/Droidnix/Prompt +++ b/Droidnix/Prompt @@ -1,145 +1,38 @@ -Rewrite my ./generated/modules/traveldroid/desktop/stylix.nix to integrate nicely with my existing flake.nix en host.nix +Rewrite my ./generated/modules/traveldroid/system/bluetooth.nix to integrate nicely with my existing flake.nix en host.nix Avoid infinite recursion Just look at how to rewrite this, ignore previous interactions around this nix. Solve the error. That is really important. Look at hyprland.nix to see how to avoid the home error -{ lib, config, pkgs, flakeRoot, ... }: -let - username = config.defaultUser or "henrov"; - moduleName = "stylix"; - - # Path to stylix assets - assetPath = "${flakeRoot}/assets/system/conf/${moduleName}"; - - # Read all files in the asset directory - programFiles = builtins.readDir assetPath; - - files = lib.genAttrs (builtins.attrNames programFiles) (name: { - source = "${assetPath}/${name}"; - }); - - # Optional stylix.conf - stylixConfFile = "${assetPath}/stylix.conf"; - stylixConf = - if builtins.pathExists stylixConfFile - then builtins.readFile stylixConfFile - else ""; - - # Cursor defaults - cursorName = "phinger-cursors-light"; - cursorSize = 24; -in -{ - ################################# - # System packages - ################################# - environment.systemPackages = [ - pkgs.feh - pkgs.st - ]; - - ################################# - # Home Manager user-level configuration - ################################# - _module.args.hmUsers = { - "${username}" = { - # Copy all stylix config files into ~/.config/stylix/ - home.file = lib.mkMerge (lib.mapAttrs' (name: value: { - name = "${moduleName}/${name}"; - value = { inherit (value) source; }; - }) files); - - # Include stylix.conf if it exists - home.file."${moduleName}/stylix.conf".text = stylixConf; - - # Session variables for Stylix & cursors - home.sessionVariables = { - STYLIX_CONF = "$HOME/.config/stylix/stylix.conf"; - XCURSOR_THEME = cursorName; - XCURSOR_SIZE = toString cursorSize; - HYPRCURSOR_THEME = cursorName; - HYPRCURSOR_SIZE = toString cursorSize; - }; - }; - }; -} ------------------------------------------------------------------------ -{ lib, config, pkgs, flakeRoot, ... }: -let - username = config.defaultUser or "henrov"; - moduleName = "stylix"; +{ config, pkgs, ... }: - # Path to stylix assets - assetPath = ../../../assets/system/conf/${moduleName}; - - # Read all files in the asset directory - programFiles = builtins.readDir assetPath; - - files = lib.genAttrs (builtins.attrNames programFiles) (name: { - source = "${assetPath}/${name}"; - }); - - # Optional stylix.conf - stylixConfFile = "${assetPath}/stylix.conf"; - stylixConf = - if builtins.pathExists stylixConfFile - then builtins.readFile stylixConfFile - else ""; - - # Cursor defaults - cursorName = "phinger-cursors-light"; - cursorSize = 24; -in { ############################ - # System packages + # Bluetooth hardware ############################ - environment.systemPackages = [ - pkgs.feh - pkgs.st + hardware.bluetooth = { + enable = true; # turn on the daemon + powerOnBoot = true; # auto-power on + package = pkgs.bluez; # singular, not a list + }; + + ############################ + # GUI Bluetooth manager + ############################ + environment.systemPackages = with pkgs; [ + blueman # graphical Bluetooth manager ]; - stylix = { - enable = true; - base16Scheme = "${flakeRoot}/assets/system/theming/stylix/catppuccin-mocha.yaml"; - polarity = "dark"; - targets = { - gtk = { enable = true; }; - }; - }; - ############################ - # Home Manager user settings + # PipeWire for Bluetooth audio ############################ - # Use the _module.args.hmUsers style to avoid "option does not exist" - _module.args.hmUsers = { - "${username}" = { - # Copy all stylix config files into ~/.config/stylix/ - xdg.configFile = - lib.mapAttrs' (name: value: { - name = "${moduleName}/${name}"; - value = { inherit (value) source; }; - }) files; - - # Optionally include stylix.conf - home.file."${moduleName}/stylix.conf".text = stylixConf; - - # Session variables - home.sessionVariables = { - STYLIX_CONF = "$HOME/.config/stylix/stylix.conf"; - - XCURSOR_THEME = cursorName; - XCURSOR_SIZE = toString cursorSize; - HYPRCURSOR_THEME = cursorName; - HYPRCURSOR_SIZE = toString cursorSize; - }; - }; - }; + # services.pipewire.enable = true; } + ------------------------------------------------------------------------ flake.nix diff --git a/Droidnix/README.org b/Droidnix/README.org index ceca6afac..d842a434d 100644 --- a/Droidnix/README.org +++ b/Droidnix/README.org @@ -920,6 +920,45 @@ in * generated/modules/traveldroid/system +** =generated/modules/traveldroid/system/bluetooth.nix= +#+BEGIN_SRC nix :tangle generated/modules/traveldroid/system/bluetooth.nix :noweb tangle :mkdirp yes :eval never-html +{ lib, config, pkgs, flakeRoot, home-manager, ... }: + +let + username = config.defaultUser or "henrov"; +in +{ + ############################ + # Bluetooth daemon + ############################ + hardware.bluetooth = { + enable = true; + powerOnBoot = true; + package = pkgs.bluez; # singular, not a list + }; + + ############################ + # GUI Bluetooth manager + ############################ + environment.systemPackages = with pkgs; [ + blueman + ]; + + ############################ + # Optional Home Manager integration + ############################ + _module.args.hmUsers = lib.mkIf (home-manager != null) { + ${username} = { + # If you want a graphical tray or manager accessible in user session + home.packages = [ pkgs.blueman ]; + + # Example: could drop any config files for blueman here + home.file = {}; + }; + }; +} +#+END_SRC + ** =generated/modules/traveldroid/system/dbus.nix= This sets the dbus implementation #+BEGIN_SRC nix :tangle generated/modules/traveldroid/system/dbus.nix :noweb tangle :mkdirp yes :eval never-html diff --git a/Droidnix/generated/modules/traveldroid/system/bluetooth.nix b/Droidnix/generated/modules/traveldroid/system/bluetooth.nix new file mode 100644 index 000000000..dcd0fe6f5 --- /dev/null +++ b/Droidnix/generated/modules/traveldroid/system/bluetooth.nix @@ -0,0 +1,35 @@ +{ lib, config, pkgs, flakeRoot, home-manager, ... }: + +let + username = config.defaultUser or "henrov"; +in +{ + ############################ + # Bluetooth daemon + ############################ + hardware.bluetooth = { + enable = true; + powerOnBoot = true; + package = pkgs.bluez; # singular, not a list + }; + + ############################ + # GUI Bluetooth manager + ############################ + environment.systemPackages = with pkgs; [ + blueman + ]; + + ############################ + # Optional Home Manager integration + ############################ + _module.args.hmUsers = lib.mkIf (home-manager != null) { + ${username} = { + # If you want a graphical tray or manager accessible in user session + home.packages = [ pkgs.blueman ]; + + # Example: could drop any config files for blueman here + home.file = {}; + }; + }; +}