From 0f4ce11546786e95dd3880332d6b63b18d036755 Mon Sep 17 00:00:00 2001 From: "info@data-pro.nu" Date: Fri, 13 Mar 2026 19:45:07 +0100 Subject: [PATCH] Further modularization of machine --- Droidnix/README.html | 794 ++++++++++-------- Droidnix/README.org | 77 +- .../flake/machines/traveldroid/audio.nix | 16 + .../flake/machines/traveldroid/dbus.nix | 8 + .../assets/flake/machines/traveldroid/top.nix | 3 + .../assets/flake/machines/traveldroid/xdg.nix | 7 + Droidnix/generated/system/core/wayland.nix | 23 - 7 files changed, 505 insertions(+), 423 deletions(-) create mode 100644 Droidnix/assets/flake/machines/traveldroid/audio.nix create mode 100644 Droidnix/assets/flake/machines/traveldroid/dbus.nix create mode 100644 Droidnix/assets/flake/machines/traveldroid/xdg.nix diff --git a/Droidnix/README.html b/Droidnix/README.html index 1dcb54546..132b993e3 100644 --- a/Droidnix/README.html +++ b/Droidnix/README.html @@ -3,7 +3,7 @@ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> - + Droidnix: A Dendritic NixOS + Home Manager Configuration NixOS Configuration Structure @@ -204,125 +204,128 @@

Table of Contents

-
-

Shortcuts

-
+
+

Shortcuts

+

Introduction The Assets Folder @@ -338,26 +341,26 @@

Introduction   intro

-
-

What is Droidnix

-
+
+

What is Droidnix

+

Droidnix is a modular, declarative NixOS + Home Manager configuration system. It allows users to choose between Hyprland and Mangowc as their window manager, with shared and WM-specific configurations managed via Emacs Org and Nix Flakes. The project is designed for reproducibility, maintainability, and cross-machine compatibility.

-
-

Installed components:

-
+
+

Installed components:

+
    -
  • Core
  • -
  • Hyprland
  • -
  • Mangowc
  • +
  • Core
  • +
  • Hyprland
  • +
  • Mangowc
-
-

Goals, project Structure, import hierarchy

-
+
+

Goals, project Structure, import hierarchy

+

This project uses a modular NixOS configuration with Hyprland and MangoWC support, designed for literate programming and cross-device reusability. The Droidnix repository is organized into two main parts: @@ -370,9 +373,9 @@ The Droidnix repository is organized into two main parts:

-
-

Root Level

-
+
+

Root Level

+
  • flake.nix is the entry point and imports:
      @@ -384,23 +387,23 @@ The Droidnix repository is organized into two main parts:
-
-

Generated Structure

-
+
+

Generated Structure

+

The generated/ directory contains all generated configurations, divided into three main groups: system, hyprland, and mangowc.

-
-

System (generated/system/)

-
+
+

System (generated/system/)

+

This directory contains system-wide configurations that are independent of the window manager.

-
-

Applications (applications/)

-
+
+

Applications (applications/)

+
  • file_management/: Configurations for file managers and storage solutions.
  • gaming/: Settings for gaming-related software.
  • @@ -410,9 +413,9 @@ This directory contains system-wide configurations that are independent of the w
-
-

Development (development/)

-
+
+

Development (development/)

+
  • databases/: Settings for local databases.
  • devops_ci_cd/: Configurations for DevOps tools.
  • @@ -422,9 +425,9 @@ This directory contains system-wide configurations that are independent of the w
-
-

System Management (system_management/)

-
+
+

System Management (system_management/)

+
  • backups/: Settings for backup software.
  • bluetooth/: Configurations for Bluetooth devices and services.
  • @@ -443,9 +446,9 @@ This directory contains system-wide configurations that are independent of the w
-
-

Hyprland (generated/hyprland/)

-
+
+

Hyprland (generated/hyprland/)

+

This directory contains configurations specific to Hyprland.

@@ -462,9 +465,9 @@ This directory contains configurations specific to Hyprland.
-
-

MangoWC (generated/mangowc/)

-
+
+

MangoWC (generated/mangowc/)

+

This directory contains configurations specific to MangoWC.

@@ -498,7 +501,7 @@ This directory contains configurations specific to MangoWC.
  • Scalability: Easy to add new machines or configurations.
  • -
    +
     .
     ├── assets
     │   ├── system
    @@ -680,9 +683,9 @@ This directory contains configurations specific to MangoWC.
     
    -
    -

    First Setup

    -
    +
    +

    First Setup

    +
    1. Clone this repository.
    2. Run the setup script: ./setup_droidnix.sh.
    3. @@ -704,9 +707,9 @@ This directory contains configurations specific to MangoWC. The .assets/ folder contains all static files, such as configs, scripts, and themes. These files are not generated and can be edited directly.

    -
    -

    .assets/system/

    -
    +
    +

    .assets/system/

    +

    This folder contains files shared across both window managers, such as wallpapers, shell configs, and system scripts.

    @@ -717,9 +720,9 @@ This folder contains files shared across both window managers, such as wallpaper
    -
    -

    .assets/hyprland/

    -
    +
    +

    .assets/hyprland/

    +

    Hyprland-specific assets, including configs, themes, and scripts.

    @@ -731,9 +734,9 @@ Hyprland-specific assets, including configs, themes, and scripts.
    -
    -

    .assets/mangowc/

    -
    +
    +

    .assets/mangowc/

    +

    Mangowc-specific assets, including configs, themes, and scripts.

    @@ -745,9 +748,9 @@ Mangowc-specific assets, including configs, themes, and scripts.
    -
    -

    .assets/machines/

    -
    +
    +

    .assets/machines/

    +

    Machine-specific NixOS configurations (e.g., configuration.nix for maindroid and traveldroid).

    @@ -765,9 +768,9 @@ Machine-specific NixOS configurations (e.g., configuration.nix for This section contains the Org blocks for tangling Nix code into the generated folders.

    -
    -

    flake.nix

    -
    +
    +

    flake.nix

    +

    The Nix flake definition for Droidnix.

    @@ -863,13 +866,13 @@ The Nix flake definition for Droidnix.
    -
    -

    First the nix-files that flake really needs and that do not fit wel in the hierarchical structure

    -
    +
    +

    First the nix-files that flake really needs and that do not fit wel in the hierarchical structure

    +
    -
    -

    assets/flake/users/top.nix

    -
    +
    +

    assets/flake/users/top.nix

    +

    The ./generated/top.nix file acts as an anchor or entry point for the entire chain of imports in the pyramid structure.

    @@ -884,9 +887,9 @@ The ./generated/top.nix file acts as an anchor or entry point for the entire cha
    -
    -

    assets/flake/users/user.nix

    -
    +
    +

    assets/flake/users/user.nix

    +

    This is the default user, just search and replace henrov another name if you want to change

    @@ -917,9 +920,9 @@ in
    -
    -

    assets/flake/users/henrov.nix

    -
    +
    +

    assets/flake/users/henrov.nix

    +

    This is the default user, just search and replace henrov another name if you want to change

    @@ -935,9 +938,9 @@ This is the default user, just search and replace henrov another name if you wan
    -
    -

    assets/flake/terminal_shell/devshell.nix

    -
    +
    +

    assets/flake/terminal_shell/devshell.nix

    +

    This code defines a Nix shell environment (also called a "devShell") that you can enter using the nix develop command. When you enter this shell, Nix will provide the tools and dependencies listed in buildInputs.

    @@ -953,9 +956,9 @@ mkShell {
    -
    -

    assets/flake/machines/traveldroid/top.nix

    -
    +
    +

    assets/flake/machines/traveldroid/top.nix

    +

    This is the top of the machine hierarchy

    @@ -975,6 +978,9 @@ This is the top of the machine hierarchy ./boot.nix ./hardware-configuration.nix ./machine.nix + ./dbus.nix + ./audio.nix + ./xdg.nix inputs.home-manager.nixosModules.home-manager ]; } @@ -982,9 +988,9 @@ This is the top of the machine hierarchy
    -
    -

    assets/flake/machines/traveldroid/boot.nix

    -
    +
    +

    assets/flake/machines/traveldroid/boot.nix

    +

    This file has most of the settings the control how the computer boots up.

    @@ -1018,9 +1024,9 @@ This file has most of the settings the control how the computer boots up.
    -
    -

    assets/flake/machines/traveldroid/machine.nix

    -
    +
    +

    assets/flake/machines/traveldroid/machine.nix

    +

    This is the top if the machine hierarchy

    @@ -1067,14 +1073,79 @@ This is the top if the machine hierarchy
    +
    +

    assets/flake/machines/traveldroid/dbus.nix

    +
    +

    +This sets the dbus implementation +

    +
    +
    { config, pkgs, ... }:
    +{
    +  services.dbus = {
    +    enable = true;
    +    package = pkgs.dbus-broker; # Use dbus-broker for performance
    +  };
    +  services.dbus-broker.enable = true; # Explicitly enable the broker
    +}
    +
    -
    -

    Now we reach the top of the hierarchy which will call all other imports

    -
    -
    -

    generated/top.nix

    -
    +
    +
    +

    assets/flake/machines/traveldroid/audio.nix

    +
    +

    +This sets audiosystem for this machine +

    +
    +
    { config, pkgs, ... }:
    +{
    +  services.pipewire = {
    +    enable = true;
    +    alsa.enable = true;    # ALSA compatibility
    +    pulse.enable = true;   # PulseAudio compatibility
    +    wireplumber.enable = true; # Session manager for PipeWire
    +  };
    +  # Optional: Add realtime privileges for pro audio (if needed)
    +  security.rtkit.enable = true;
    +  # Optional: Enable Bluetooth audio support
    +  services.bluez = {
    +    enable = true;
    +    audioSupport = true;
    +  };
    +}
    +
    +
    +
    +
    +
    +

    assets/flake/machines/traveldroid/xdg.nix

    +
    +

    +This sets the XDG implementation +

    +
    +
    { config, pkgs, ... }:
    +{
    +  xdg.portal = {
    +    enable = true;
    +    config.system.default = [ "hyprland" "gtk" ];
    +  };
    +}
    +
    +
    +
    +
    +
    +
    +
    +

    Now we reach the top of the hierarchy which will call all other imports

    +
    +
    +
    +

    generated/top.nix

    +

    The ./generated/top.nix file acts as an anchor or entry point for the entire chain of imports in the pyramid structure.

    @@ -1113,9 +1184,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/hyprland/hyprland.nix

    -
    +
    +

    generated/hyprland/hyprland.nix

    +

    The ./generated/top.nix file acts as an anchor or entry point for the entire chain of imports in the pyramid structure.

    @@ -1168,9 +1239,9 @@ in
    -
    -

    generated/mangowc/top.nix

    -
    +
    +

    generated/mangowc/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1193,9 +1264,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/top.nix

    -
    +
    +

    generated/system/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1214,9 +1285,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/applications/top.nix

    -
    +
    +

    generated/system/applications/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1239,9 +1310,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/applications/packages.nix

    -
    +
    +

    generated/system/applications/packages.nix

    +

    This will import all packages listed in ./assets/system/apps/packlages.conf

    @@ -1294,9 +1365,9 @@ in
    -
    -

    generated/system/applications/flatpaks.nix

    -
    +
    +

    generated/system/applications/flatpaks.nix

    +

    This will import all packages listed in ./assets/system/apps/flatpaks.conf

    @@ -1417,9 +1488,9 @@ in
    -
    -

    generated/system/core/top.nix

    -
    +
    +

    generated/system/core/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1439,9 +1510,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/core/fonts.nix

    -
    +
    +

    generated/system/core/fonts.nix

    +

    This file installs and configures eww

    @@ -1456,9 +1527,9 @@ This file installs and configures eww
    -
    -

    generated/system/core/eww.nix

    -
    +
    +

    generated/system/core/eww.nix

    +

    This file installs and configures eww

    @@ -1502,9 +1573,9 @@ in
    -
    -

    generated/system/core/waybar.nix

    -
    +
    +

    generated/system/core/waybar.nix

    +

    This file installs and configures waybar

    @@ -1544,9 +1615,9 @@ in
    -
    -

    generated/system/core/login-tuigreeter.nix

    -
    +
    +

    generated/system/core/login-tuigreeter.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1569,38 +1640,15 @@ settings = {
    -
    -

    generated/system/core/wayland.nix

    -
    +
    +

    generated/system/core/wayland.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    { config, pkgs, lib, user, ... }:
     {
    -  # Enable essential services for a Wayland session
    -  services.dbus.enable = true;
    -  services.pipewire = {
    -    enable = true;
    -    alsa.enable = true;
    -    pulse.enable = true;
    -    wireplumber.enable = true;
    -  };
    -
    -  # XDG Desktop Portal settings for better application integration
    -  xdg.portal = {
    -    enable = true;
    -    config.system.default = [ "hyprland" "gtk" ];
    -  };
    -
    -  # Environment variables for a Wayland session
    -  environment.sessionVariables = {
    -    XDG_SESSION_TYPE = "wayland";
    -    XDG_CURRENT_DESKTOP = "Hyprland";
    -    XCURSOR_SIZE = "24";
    -  };
    -
    -  # Home Manager Wayland configurations
       home-manager.users.${user.username} = {
         xdg.portal = {
           enable = true;
    @@ -1615,9 +1663,9 @@ This is top file of this level which contains just an import statement for all r
     
    -
    -

    generated/system/development/top.nix

    -
    +
    +

    generated/system/development/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1637,9 +1685,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/top.nix

    -
    +
    +

    generated/system/system_management/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1667,9 +1715,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/hyprland/animations_effects/top.nix

    -
    +
    +

    generated/hyprland/animations_effects/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1685,9 +1733,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/hyprland/decorations/top.nix

    -
    +
    +

    generated/hyprland/decorations/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1703,9 +1751,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/hyprland/keyboard_binds/top.nix

    -
    +
    +

    generated/hyprland/keyboard_binds/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1734,9 +1782,9 @@ in
    -
    -

    generated/hyprland/notifications/top.nix

    -
    +
    +

    generated/hyprland/notifications/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1752,9 +1800,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/hyprland/statusbar_tray/top.nix

    -
    +
    +

    generated/hyprland/statusbar_tray/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1770,9 +1818,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/hyprland/task_launcher/top.nix

    -
    +
    +

    generated/hyprland/task_launcher/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1788,9 +1836,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/task_launcher/wofi.nix

    -
    +
    +

    generated/system/task_launcher/wofi.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1835,9 +1883,9 @@ in
    -
    -

    generated/hyprland/task_window_workspace_switcher/top.nix

    -
    +
    +

    generated/hyprland/task_window_workspace_switcher/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1853,9 +1901,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/hyprland/window_rules/top.nix

    -
    +
    +

    generated/hyprland/window_rules/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1871,9 +1919,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/mangowc/animations_effects/top.nix

    -
    +
    +

    generated/mangowc/animations_effects/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1889,9 +1937,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/mangowc/decorations/top.nix

    -
    +
    +

    generated/mangowc/decorations/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1907,9 +1955,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/mangowc/keyboard_binds/top.nix

    -
    +
    +

    generated/mangowc/keyboard_binds/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1919,9 +1967,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/mangowc/notifications/top.nix

    -
    +
    +

    generated/mangowc/notifications/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1937,9 +1985,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/mangowc/statusbar_tray/top.nix

    -
    +
    +

    generated/mangowc/statusbar_tray/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1955,9 +2003,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/mangowc/task_launcher/top.nix

    -
    +
    +

    generated/mangowc/task_launcher/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1973,9 +2021,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/mangowc/task_window_workspace_switcher/top.nix

    -
    +
    +

    generated/mangowc/task_window_workspace_switcher/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -1991,9 +2039,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/mangowc/window_rules/top.nix

    -
    +
    +

    generated/mangowc/window_rules/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2009,9 +2057,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/applications/accessibility/top.nix

    -
    +
    +

    generated/system/applications/accessibility/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2027,9 +2075,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/applications/file_management/top.nix

    -
    +
    +

    generated/system/applications/file_management/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2045,9 +2093,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/applications/gaming/top.nix

    -
    +
    +

    generated/system/applications/gaming/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2063,9 +2111,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/applications/media_playback_editing/top.nix

    -
    +
    +

    generated/system/applications/media_playback_editing/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2081,9 +2129,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/applications/office_productivity/top.nix

    -
    +
    +

    generated/system/applications/office_productivity/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2099,9 +2147,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/applications/terminal_shell/top.nix

    -
    +
    +

    generated/system/applications/terminal_shell/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2119,9 +2167,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/applications/terminal_shell/kitty.nix

    -
    +
    +

    generated/system/applications/terminal_shell/kitty.nix

    +

    This file sets up Kitty terminal

    @@ -2149,9 +2197,9 @@ in
    -
    -

    generated/system/applications/terminal_shell/starship.nix

    -
    +
    +

    generated/system/applications/terminal_shell/starship.nix

    +

    This file sets up starship prompt

    @@ -2176,9 +2224,9 @@ in
    -
    -

    generated/system/applications/terminal_shell/zsh.nix

    -
    +
    +

    generated/system/applications/terminal_shell/zsh.nix

    +

    This sets up the zsh terminal

    @@ -2283,9 +2331,9 @@ This sets up the zsh terminal
    -
    -

    generated/system/development/databases/top.nix

    -
    +
    +

    generated/system/development/databases/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2301,9 +2349,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/development/devops_ci_cd/top.nix

    -
    +
    +

    generated/system/development/devops_ci_cd/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2319,9 +2367,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/development/programming_languages/top.nix

    -
    +
    +

    generated/system/development/programming_languages/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2337,9 +2385,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/development/virtualization/top.nix

    -
    +
    +

    generated/system/development/virtualization/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2355,9 +2403,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/development/web_development/top.nix

    -
    +
    +

    generated/system/development/web_development/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2373,9 +2421,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/audio/top.nix

    -
    +
    +

    generated/system/system_management/audio/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2391,9 +2439,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/backups/top.nix

    -
    +
    +

    generated/system/system_management/backups/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2409,9 +2457,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/bluetooth/top.nix

    -
    +
    +

    generated/system/system_management/bluetooth/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2427,9 +2475,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/disk_management/top.nix

    -
    +
    +

    generated/system/system_management/disk_management/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2445,9 +2493,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/hardware_sensors/top.nix

    -
    +
    +

    generated/system/system_management/hardware_sensors/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2463,9 +2511,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/logging_monitoring/top.nix

    -
    +
    +

    generated/system/system_management/logging_monitoring/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2481,9 +2529,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/login_manager/top.nix

    -
    +
    +

    generated/system/system_management/login_manager/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2499,9 +2547,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/monitor_setup/top.nix

    -
    +
    +

    generated/system/system_management/monitor_setup/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2517,9 +2565,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/networking/top.nix

    -
    +
    +

    generated/system/system_management/networking/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2535,9 +2583,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/power_management/top.nix

    -
    +
    +

    generated/system/system_management/power_management/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2553,9 +2601,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/printers_scanners/top.nix

    -
    +
    +

    generated/system/system_management/printers_scanners/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2571,9 +2619,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/security/top.nix

    -
    +
    +

    generated/system/system_management/security/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2589,9 +2637,9 @@ This is top file of this level which contains just an import statement for all r
    -
    -

    generated/system/system_management/system_updates/top.nix

    -
    +
    +

    generated/system/system_management/system_updates/top.nix

    +

    This is top file of this level which contains just an import statement for all relevant files and/or the subfolder in this folder

    @@ -2611,7 +2659,7 @@ This is top file of this level which contains just an import statement for all r

    Author: Henro Veijer

    -

    Created: 2026-03-13 vr 17:31

    +

    Created: 2026-03-13 vr 19:44

    Validate

    diff --git a/Droidnix/README.org b/Droidnix/README.org index 748f4d797..1b1ea28fc 100644 --- a/Droidnix/README.org +++ b/Droidnix/README.org @@ -511,6 +511,9 @@ This is the top of the machine hierarchy ./boot.nix ./hardware-configuration.nix ./machine.nix + ./dbus.nix + ./audio.nix + ./xdg.nix inputs.home-manager.nixosModules.home-manager ]; } @@ -589,6 +592,53 @@ This is the top if the machine hierarchy } #+END_SRC +** =assets/flake/machines/traveldroid/dbus.nix= +This sets the dbus implementation +#+BEGIN_SRC nix :tangle assets/flake/machines/traveldroid/dbus.nix :noweb tangle :mkdirp yes :eval never-html +{ config, pkgs, ... }: +{ + services.dbus = { + enable = true; + package = pkgs.dbus-broker; # Use dbus-broker for performance + }; + services.dbus-broker.enable = true; # Explicitly enable the broker +} +#+END_SRC + +** =assets/flake/machines/traveldroid/audio.nix= +This sets audiosystem for this machine +#+BEGIN_SRC nix :tangle assets/flake/machines/traveldroid/audio.nix :noweb tangle :mkdirp yes :eval never-html +{ config, pkgs, ... }: +{ + services.pipewire = { + enable = true; + alsa.enable = true; # ALSA compatibility + pulse.enable = true; # PulseAudio compatibility + wireplumber.enable = true; # Session manager for PipeWire + }; + # Optional: Add realtime privileges for pro audio (if needed) + security.rtkit.enable = true; + # Optional: Enable Bluetooth audio support + services.bluez = { + enable = true; + audioSupport = true; + }; +} +#+END_SRC + +** =assets/flake/machines/traveldroid/xdg.nix= +This sets the XDG implementation +#+BEGIN_SRC nix :tangle assets/flake/machines/traveldroid/xdg.nix :noweb tangle :mkdirp yes :eval never-html +{ config, pkgs, ... }: +{ + xdg.portal = { + enable = true; + config.system.default = [ "hyprland" "gtk" ]; + }; +} + +#+END_SRC + * Now we reach the top of the hierarchy which will call all other imports ** =generated/top.nix= @@ -1021,33 +1071,6 @@ This is top file of this level which contains just an import statement for all r #+BEGIN_SRC nix :tangle generated/system/core/wayland.nix :noweb tangle :mkdirp yes :eval never-html { config, pkgs, lib, user, ... }: { - # Enable essential services for a Wayland session - services.dbus = { - enable = true; - package = pkgs.dbus-broker; # Explicitly use dbus-broker - } - services.dbus-broker.enable = true; # Enable the broker service - services.pipewire = { - enable = true; - alsa.enable = true; - pulse.enable = true; - wireplumber.enable = true; - }; - - # XDG Desktop Portal settings for better application integration - xdg.portal = { - enable = true; - config.system.default = [ "hyprland" "gtk" ]; - }; - - # Environment variables for a Wayland session - environment.sessionVariables = { - XDG_SESSION_TYPE = "wayland"; - XDG_CURRENT_DESKTOP = "Hyprland"; - XCURSOR_SIZE = "24"; - }; - - # Home Manager Wayland configurations home-manager.users.${user.username} = { xdg.portal = { enable = true; diff --git a/Droidnix/assets/flake/machines/traveldroid/audio.nix b/Droidnix/assets/flake/machines/traveldroid/audio.nix new file mode 100644 index 000000000..725a84610 --- /dev/null +++ b/Droidnix/assets/flake/machines/traveldroid/audio.nix @@ -0,0 +1,16 @@ +{ config, pkgs, ... }: +{ + services.pipewire = { + enable = true; + alsa.enable = true; # ALSA compatibility + pulse.enable = true; # PulseAudio compatibility + wireplumber.enable = true; # Session manager for PipeWire + }; + # Optional: Add realtime privileges for pro audio (if needed) + security.rtkit.enable = true; + # Optional: Enable Bluetooth audio support + services.bluez = { + enable = true; + audioSupport = true; + }; +} diff --git a/Droidnix/assets/flake/machines/traveldroid/dbus.nix b/Droidnix/assets/flake/machines/traveldroid/dbus.nix new file mode 100644 index 000000000..af8b672f1 --- /dev/null +++ b/Droidnix/assets/flake/machines/traveldroid/dbus.nix @@ -0,0 +1,8 @@ +{ config, pkgs, ... }: +{ + services.dbus = { + enable = true; + package = pkgs.dbus-broker; # Use dbus-broker for performance + }; + services.dbus-broker.enable = true; # Explicitly enable the broker +} diff --git a/Droidnix/assets/flake/machines/traveldroid/top.nix b/Droidnix/assets/flake/machines/traveldroid/top.nix index 89115bb81..c8f65041c 100644 --- a/Droidnix/assets/flake/machines/traveldroid/top.nix +++ b/Droidnix/assets/flake/machines/traveldroid/top.nix @@ -13,6 +13,9 @@ ./boot.nix ./hardware-configuration.nix ./machine.nix + ./dbus.nix + ./audio.nix + ./xdg.nix inputs.home-manager.nixosModules.home-manager ]; } diff --git a/Droidnix/assets/flake/machines/traveldroid/xdg.nix b/Droidnix/assets/flake/machines/traveldroid/xdg.nix new file mode 100644 index 000000000..ed37e204f --- /dev/null +++ b/Droidnix/assets/flake/machines/traveldroid/xdg.nix @@ -0,0 +1,7 @@ +{ config, pkgs, ... }: +{ + xdg.portal = { + enable = true; + config.system.default = [ "hyprland" "gtk" ]; + }; +} diff --git a/Droidnix/generated/system/core/wayland.nix b/Droidnix/generated/system/core/wayland.nix index 53ae92f71..9d7e5e81d 100644 --- a/Droidnix/generated/system/core/wayland.nix +++ b/Droidnix/generated/system/core/wayland.nix @@ -1,28 +1,5 @@ { config, pkgs, lib, user, ... }: { - # Enable essential services for a Wayland session - services.dbus.enable = true; - services.pipewire = { - enable = true; - alsa.enable = true; - pulse.enable = true; - wireplumber.enable = true; - }; - - # XDG Desktop Portal settings for better application integration - xdg.portal = { - enable = true; - config.system.default = [ "hyprland" "gtk" ]; - }; - - # Environment variables for a Wayland session - environment.sessionVariables = { - XDG_SESSION_TYPE = "wayland"; - XDG_CURRENT_DESKTOP = "Hyprland"; - XCURSOR_SIZE = "24"; - }; - - # Home Manager Wayland configurations home-manager.users.${user.username} = { xdg.portal = { enable = true;