From 6b0bf40e206a8d8adc510536afcf6e2035785a8e Mon Sep 17 00:00:00 2001 From: Don Williams Date: Sat, 30 Aug 2025 20:06:24 -0400 Subject: [PATCH 01/18] Changed branch nstall clones to stable-2.4 On branch stable-2.4 Your branch is up to date with 'origin/stable-2.4'. Changes to be committed: modified: install-zaneyos.sh --- install-zaneyos.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install-zaneyos.sh b/install-zaneyos.sh index ed6e5f4..cffc0fd 100755 --- a/install-zaneyos.sh +++ b/install-zaneyos.sh @@ -219,7 +219,7 @@ else fi print_header "Cloning ZaneyOS Repository" -git clone https://gitlab.com/zaney/zaneyos.git --depth=1 ~/zaneyos +git clone https://gitlab.com/zaney/zaneyos.git -b stable-2.4 --depth=1 ~/zaneyos cd ~/zaneyos || exit 1 print_header "Git Configuration" From fd992cc1ae15d805ec9dbddba80210646732d967 Mon Sep 17 00:00:00 2001 From: Don Williams Date: Sat, 30 Aug 2025 20:11:04 -0400 Subject: [PATCH 02/18] Added announcement in English / Spanish On branch stable-2.4 Your branch is up to date with 'origin/stable-2.4'. Changes to be committed: new file: ZaneyOS-stable-2.4-announcement.es.md new file: ZaneyOS-stable-2.4-announcement.md --- ZaneyOS-stable-2.4-announcement.es.md | 35 +++++++++++++++++++++++++++ ZaneyOS-stable-2.4-announcement.md | 35 +++++++++++++++++++++++++++ 2 files changed, 70 insertions(+) create mode 100644 ZaneyOS-stable-2.4-announcement.es.md create mode 100644 ZaneyOS-stable-2.4-announcement.md diff --git a/ZaneyOS-stable-2.4-announcement.es.md b/ZaneyOS-stable-2.4-announcement.es.md new file mode 100644 index 0000000..0bd2ea9 --- /dev/null +++ b/ZaneyOS-stable-2.4-announcement.es.md @@ -0,0 +1,35 @@ +# ¡ZaneyOS v2.4 ya está aquí! 🚀 + +Nos complace anunciar ZaneyOS v2.4: una versión centrada en mejorar la experiencia de escritorio, simplificar la personalización y fortalecer las herramientas. + +Destacados +- Nuevo gestor de inicio predeterminado: SDDM con un greeter tematizado para una experiencia de inicio pulida +- Conmutadores de funciones en las variables del host: Activa o desactiva componentes fácilmente en `hosts//variables.nix` + - Terminales (kitty, wezterm, ghostty, alacritty) + - Perfiles de Waybar y animaciones + - Thunar, impresión, NFS, elección de navegador, etc. + - Selección del gestor de inicio mediante `displayManager` +- zcli actualizado: mejores flujos y utilidades (incluye bootstrap para Doom Emacs) +- Doom Emacs: interruptor de primera clase + ruta de instalación más sencilla (`zcli doom install` tras habilitarlo) +- Estructura de configuración mejorada: separación más clara, actualizaciones más seguras y valores por defecto más coherentes +- Mejoras en Fastfetch: muestra la versión de ZaneyOS de forma dinámica +- Documentación: ha empezado el esfuerzo de traducción al español (¡gracias!) + +Enlaces +- GitLab: https://gitlab.com/zaney/zaneyos +- README: https://gitlab.com/zaney/zaneyos/-/blob/stable-2.4/README.md + + + +⚠️ NOTAS IMPORTANTES DE ACTUALIZACIÓN (LEE ESTO) +- El script de actualización SOLO está pensado para pasar de v2.3 → v2.4. +- Si tienes una v2.3 muy modificada, NO uses el script de actualización. Considera una instalación limpia de v2.4 y migra tus cambios manualmente. +- Copias de seguridad: Los scripts de instalación y actualización hacen copia de tu `~/zaneyos` actual, pero recomendamos encarecidamente que hagas tu propia copia de seguridad adicional. +- Reversión: Hay un script de reversión (por ejemplo, `./revert-to-2.3.sh`) si necesitas volver atrás usando tu copia de seguridad. +- Alcance: No podemos probar todas las combinaciones y personalizaciones posibles al actualizar de v2.3 a v2.4. Procede con cuidado y revisa las diferencias. + +Nota sobre la rama +- v2.4 está publicada en la rama `stable-2.4`. + +¡Gracias por usar ZaneyOS! 🎉 + diff --git a/ZaneyOS-stable-2.4-announcement.md b/ZaneyOS-stable-2.4-announcement.md new file mode 100644 index 0000000..9c2cf06 --- /dev/null +++ b/ZaneyOS-stable-2.4-announcement.md @@ -0,0 +1,35 @@ +# ZaneyOS v2.4 is out! 🚀 + +We’re excited to announce ZaneyOS v2.4 — a quality-of-life release focused on a smoother desktop experience, simpler customization, and better tooling. + +Highlights +- New default display manager: SDDM with a themed greeter for a polished login experience +- Feature toggles in host variables: Easily enable/disable components in `hosts//variables.nix` + - Terminals (kitty, wezterm, ghostty, alacritty) + - Waybar presets and animations + - Thunar, Printing, NFS, Browser choice, etc. + - Display manager selection via `displayManager` +- Updated zcli: Better workflows and helpers (including Doom Emacs bootstrap) +- Doom Emacs: First-class toggle + smoother install path (`zcli doom install` after enabling) +- Improved configuration structure: Clearer separation, safer upgrades, and more consistent defaults +- Fastfetch enhancements: Shows ZaneyOS version dynamically +- Documentation: Spanish translation effort has begun (¡gracias!) + +Links +- GitLab: https://gitlab.com/zaney/zaneyos +- README: https://gitlab.com/zaney/zaneyos/-/blob/stable-2.4/README.md + + + +⚠️ IMPORTANT UPGRADE NOTES (PLEASE READ) +- The upgrade script is ONLY intended for upgrades from v2.3 → v2.4. +- If you have a heavily modified v2.3, do NOT use the upgrade script. Consider a fresh install of v2.4 and manually migrate your changes. +- Backups: The install and upgrade scripts back up your current `~/zaneyos`, but we strongly recommend making your own backup as well. +- Revert: A revert script is provided (e.g., `./revert-to-2.3.sh`) if you need to roll back using your backup. +- Scope: We cannot test every possible customization and combination when upgrading from v2.3 to v2.4. Proceed with care and review differences. + +Branch note +- v2.4 is published on the `stable-2.4` branch. + +Thank you for using ZaneyOS! 🎉 + From f3e03fa10af14574405c04c5c4108997ad07a3a8 Mon Sep 17 00:00:00 2001 From: Don Williams Date: Sun, 31 Aug 2025 08:49:03 -0400 Subject: [PATCH 03/18] Added docs on hyprland customization and nixos On branch stable-2.4 Your branch is up to date with 'origin/stable-2.4'. Changes to be committed: new file: cheatsheets/hyprland-customization-guide.md new file: cheatsheets/nix-beginner-guide.md --- cheatsheets/hyprland-customization-guide.md | 302 ++++++++++++++++++++ cheatsheets/nix-beginner-guide.md | 101 +++++++ 2 files changed, 403 insertions(+) create mode 100644 cheatsheets/hyprland-customization-guide.md create mode 100644 cheatsheets/nix-beginner-guide.md diff --git a/cheatsheets/hyprland-customization-guide.md b/cheatsheets/hyprland-customization-guide.md new file mode 100644 index 0000000..529917f --- /dev/null +++ b/cheatsheets/hyprland-customization-guide.md @@ -0,0 +1,302 @@ +# A Guide to Customizing Hyprland in ddubsOS + +This guide provides a more detailed look at how to customize your Hyprland experience in ddubsOS. We'll go through the most important configuration files, explaining what they do and how you can edit them. + +**A Word of Caution:** The configuration files are written in the Nix language. Nix has a very specific syntax, and any mistakes can prevent your system from building successfully. Always be careful when editing these files, and make sure to follow the examples closely. + +## Applying Your Changes + +After making any changes to these files, you'll need to apply them. Open a terminal and run: + +```bash +zcli rebuild +``` + +This command will rebuild your system with the new configuration. If there are any errors in your configuration, this command will fail. + +--- + +### `binds.nix` - Keybindings + +This file controls all of your keyboard and mouse shortcuts in Hyprland. + +**Location:** `modules/home/hyprland/binds.nix` + +You can change existing keybindings or add new ones. The format is a string with comma-separated values: `MODIFIER, KEY, DISPATCHER, VALUE`. + +**Example:** + +Let's say you want to change the keybinding for opening a terminal from `SUPER + Return` to `SUPER + T`. + +**Original:** + +```nix +# ... + bind = [ + # ... + "$modifier,Return,exec, ${terminal}" + # ... + ]; +# ... +``` + +**Modified:** + +```nix +# ... + bind = [ + # ... + "$modifier,T,exec, ${terminal}" + # ... + ]; +# ... +``` + +--- + +### `exec-once.nix` - Startup Applications + +This file lists the applications and commands that run automatically when you start Hyprland. + +**Location:** `modules/home/hyprland/exec-once.nix` + +You can add or remove commands from this list. Each command is a string. + +**Example:** + +If you want to start the `copyq` application every time you log in, you can add it to the list. + +**Original:** + +```nix +# ... + exec-once = [ + # ... + "pypr &" # pyprland for drop down term SUPERSHIFT + T + ]; +# ... +``` + +**Modified:** + +```nix +# ... + exec-once = [ + # ... + "pypr &" # pyprland for drop down term SUPERSHIFT + T + "copyq" + ]; +# ... +``` + +--- + +### `decoration.nix` - Window Decorations + +This file controls the appearance of window borders, shadows, and blur effects. + +**Location:** `modules/home/hyprland/decoration.nix` + +You can change values like `rounding` for rounded corners, or adjust the `blur` and `shadow` settings. + +**Example:** + +To increase the rounding of window corners from `0` to `10`. + +**Original:** + +```nix +# ... + decoration = { + rounding = 0; +# ... +``` + +**Modified:** + +```nix +# ... + decoration = { + rounding = 10; +# ... +``` + +--- + +### `env.nix` - Environment Variables + +This file sets environment variables for your Hyprland session. These can affect how applications behave. + +**Location:** `modules/home/hyprland/env.nix` + +You can add or change environment variables in this list. + +**Example:** + +To set the `MOZ_ENABLE_WAYLAND` variable to `1`, which forces Firefox to run in Wayland mode. + +**Original:** + +```nix +# ... + env = [ + # ... + "SDL_VIDEODRIVER, wayland" + # ... + ]; +# ... +``` + +**Modified:** + +```nix +# ... + env = [ + # ... + "SDL_VIDEODRIVER, wayland" + "MOZ_ENABLE_WAYLAND, 1" + # ... + ]; +# ... +``` + +--- + +### `gestures.nix` - Touchpad Gestures + +This file controls touchpad gestures, like swiping between workspaces. + +**Location:** `modules/home/hyprland/gestures.nix` + +You can enable or disable gestures and change their behavior. + +**Example:** + +To disable workspace swiping. + +**Original:** + +```nix +# ... + gestures = { + workspace_swipe = 1; +# ... +``` + +**Modified:** + +```nix +# ... + gestures = { + workspace_swipe = 0; +# ... +``` + +--- + +### `misc.nix` - Miscellaneous Settings + +This file contains various settings that don't fit into the other categories. + +**Location:** `modules/home/hyprland/misc.nix` + +You can change settings like `vrr` (Variable Refresh Rate) or `disable_hyprland_logo`. + +**Example:** + +To enable Variable Refresh Rate. + +**Original:** + +```nix +# ... + misc = { + # ... + vrr = 0; + # ... + }; +# ... +``` + +**Modified:** + +```nix +# ... + misc = { + # ... + vrr = 1; + # ... + }; +# ... +``` + +--- + +### `hyprland.nix` - Main Configuration + +This is the main Hyprland configuration file. It sets up general settings, input devices, and the window layout. + +**Location:** `modules/home/hyprland/hyprland.nix` + +You can change things like the keyboard layout, touchpad settings, and the layout engine. + +**Example:** + +To change the keyboard layout from the default to `us`. + +**Original:** + +```nix +# ... + input = { + kb_layout = "${keyboardLayout}"; +# ... +``` + +**Modified:** + +```nix +# ... + input = { + kb_layout = "us"; +# ... +``` + +--- + +### `windowrules.nix` - Window Rules + +This file defines rules for how specific windows should behave. You can make certain applications always float, open on a specific workspace, or have a certain opacity. + +**Location:** `modules/home/hyprland/windowrules.nix` + +You can add new rules to the `windowrule` list. + +**Example:** + +To make the `thunar` file manager always float. + +**Original:** + +```nix +# ... + windowrule = [ + # ... + "float, class:^(foot-floating)$" + # ... + ]; +# ... +``` + +**Modified:** + +```nix +# ... + windowrule = [ + # ... + "float, class:^(foot-floating)$" + "float, class:^(Thunar)$" + # ... + ]; +# ... +``` diff --git a/cheatsheets/nix-beginner-guide.md b/cheatsheets/nix-beginner-guide.md new file mode 100644 index 0000000..01308b9 --- /dev/null +++ b/cheatsheets/nix-beginner-guide.md @@ -0,0 +1,101 @@ +# Welcome to ddubsOS! A Beginner's Guide to Customization + +Welcome! This guide is for users who are new to Nix and want to make some common customizations to their ddubsOS setup. We'll keep it simple and focus on the essentials. + +## Understanding the Layout + +NixOS configurations can seem complex, but for day-to-day changes, you only need to know about a few key files and directories. + +- `flake.nix`: This is the main file for the entire system. You shouldn't need to edit this file directly for most common changes. +- `hosts/`: This directory contains the configuration for each individual computer (or "host") you've installed ddubsOS on. + - `hosts//`: This is where you'll make most of your changes. + - `variables.nix`: This is your main control panel. You can enable/disable features, change settings, and more. + - `host-packages.nix`: This is where you can add packages that you only want on this specific computer. +- `modules/`: This directory contains the bulk of the configuration, broken down into smaller, reusable pieces ("modules"). + - `modules/core/global-packages.nix`: You can add packages here if you want them to be installed on *all* of your ddubsOS computers. + - `modules/home/hyprland/binds.nix`: This is where you can customize your Hyprland keybindings. + +## How to Add Packages + +There are two main ways to add packages: + +### 1. For a Single Computer + +If you only want to install a package on your current computer, you'll add it to `hosts//host-packages.nix`. + +1. Open `hosts//host-packages.nix` in your favorite editor. +2. You'll see a list of packages. Simply add the name of the package you want to install to the list. For example, to add the `cowsay` package, you would change this: + + ```nix + [ + brave + (catppuccin-vsc.override { + variant = "mocha"; + }) + ] + ``` + + to this: + + ```nix + [ + brave + (catppuccin-vsc.override { + variant = "mocha"; + }) + cowsay + ] + ``` + +3. Save the file. + +### 2. For All Computers + +If you want a package to be installed on every computer you use ddubsOS on, you'll add it to `modules/core/global-packages.nix`. The process is the same as above. + +## How to Change Monitor Settings + +You can change your monitor settings in `hosts//variables.nix`. + +1. Open `hosts//variables.nix`. +2. Look for the `extraMonitorSettings` line. +3. You can add your monitor settings here. For example, to set the resolution and refresh rate for a monitor named `DP-1`, you would change this: + + ```nix + extraMonitorSettings = ""; + ``` + + to this: + + ```nix + extraMonitorSettings = "monitor=DP-1,1920x1080@144"; + ``` + +4. Save the file. + +## How to Change Hyprland Bindings + +You can change your Hyprland keybindings in `modules/home/hyprland/binds.nix`. + +1. Open `modules/home/hyprland/binds.nix`. +2. You'll see a list of keybindings. You can change them to your liking. For example, to change the keybinding for opening a terminal from `SUPER, Return` to `SUPER, T`, you would change this: + + ```nix + "SUPER, Return, exec, ${terminal}" + ``` + + to this: + + ```nix + "SUPER, T, exec, ${terminal}" + ``` + +3. Save the file. + +## Applying Your Changes + +After you've made any changes, you need to apply them. + +1. Open a terminal. +2. Run the command `zcli rebuild`. This will apply your changes to the system. +3. If the command completes successfully, your changes are now active! Some changes may require a reboot to take effect. From 6e2505ef93be46107d6f1bc3d9dd8ecc606c8290 Mon Sep 17 00:00:00 2001 From: Don Williams Date: Sun, 31 Aug 2025 09:02:05 -0400 Subject: [PATCH 04/18] docs: add Nix beginner and Hyprland customization guides (+ Spanish), link from README; prefer 'zcli rebuild' (fr deprecated) and include manual nixos-rebuild as backup --- README.es.md | 5 + README.md | 5 + .../hyprland-customization-guide.es.md | 164 ++++++++++ cheatsheets/hyprland-customization-guide.md | 285 +++++------------- cheatsheets/nix-beginner-guide.es.md | 67 ++++ cheatsheets/nix-beginner-guide.md | 131 +++----- 6 files changed, 362 insertions(+), 295 deletions(-) create mode 100644 cheatsheets/hyprland-customization-guide.es.md create mode 100644 cheatsheets/nix-beginner-guide.es.md diff --git a/README.es.md b/README.es.md index 201851e..0ae47bc 100644 --- a/README.es.md +++ b/README.es.md @@ -22,6 +22,11 @@ Incluye el fondo de pantalla, scripts, aplicaciones, archivos de configuración +### Chuletas y Guías + +- Guía para Principiantes de Nix: [English](cheatsheets/nix-beginner-guide.md) | [Español](cheatsheets/nix-beginner-guide.es.md) +- Guía de Personalización de Hyprland: [English](cheatsheets/hyprland-customization-guide.md) | [Español](cheatsheets/hyprland-customization-guide.es.md) + ### Ten en cuenta: > **Este proyecto tiene un [Wiki](https://zaney.org/wiki/zaneyos-2.3/). ¡Aprende a usar ZaneyOS aquí!** diff --git a/README.md b/README.md index ecdaf6e..f36bba6 100644 --- a/README.md +++ b/README.md @@ -22,6 +22,11 @@ This includes the wallpaper, scripts, applications, config files, and more. +### Cheatsheets and Guides + +- Nix Beginner Guide: [English](cheatsheets/nix-beginner-guide.md) | [Español](cheatsheets/nix-beginner-guide.es.md) +- Hyprland Customization Guide: [English](cheatsheets/hyprland-customization-guide.md) | [Español](cheatsheets/hyprland-customization-guide.es.md) + ### Please note: > **This project has a [Wiki](https://zaney.org/wiki/zaneyos-2.3/). Find out how diff --git a/cheatsheets/hyprland-customization-guide.es.md b/cheatsheets/hyprland-customization-guide.es.md new file mode 100644 index 0000000..4c45e75 --- /dev/null +++ b/cheatsheets/hyprland-customization-guide.es.md @@ -0,0 +1,164 @@ +# Guía de Personalización de Hyprland en ZaneyOS + +Esta guía ofrece una visión práctica para personalizar tu experiencia con Hyprland en ZaneyOS. Veremos los archivos más relevantes, qué hacen y pequeños cambios seguros que puedes aplicar. + +Nota: Estos archivos están escritos en Nix. Un pequeño error de sintaxis puede romper las compilaciones. Realiza un cambio a la vez y mantén tus ediciones bajo control de versiones. + +## Aplicar tus cambios + +Preferido (específico de ZaneyOS): +- `zcli rebuild` + - Nota: el alias `fr` está obsoleto. + +Método manual de respaldo (funciona en cualquier instalación): +- Desde la raíz del repo, reemplaza PROFILE por tu perfil (intel, nvidia, nvidia-laptop, vm): + - `sudo nixos-rebuild switch --flake .#PROFILE` + +--- + +### `binds.nix` — Atajos de teclado + +Controla atajos de teclado y ratón. + +Ubicación: `modules/home/hyprland/binds.nix` + +Formato: `MODIFICADOR, TECLA, DISPATCHER, VALOR` + +Ejemplo: Cambiar la terminal de Super+Return a Super+T + +```nix +# ... + bind = [ + # ... + "$modifier,T,exec, ${terminal}" + # ... + ]; +# ... +``` + +--- + +### `exec-once.nix` — Aplicaciones al iniciar + +Comandos que se ejecutan automáticamente con Hyprland. + +Ubicación: `modules/home/hyprland/exec-once.nix` + +Ejemplo: Añadir copyq al inicio + +```nix +# ... + exec-once = [ + # ... + "pypr &" + "copyq" + ]; +# ... +``` + +--- + +### `decoration.nix` — Bordes, sombras, desenfoque + +Ubicación: `modules/home/hyprland/decoration.nix` + +Ejemplo: Esquinas redondeadas + +```nix +# ... + decoration = { + rounding = 10; + }; +# ... +``` + +--- + +### `env.nix` — Variables de entorno + +Ubicación: `modules/home/hyprland/env.nix` + +Ejemplo: Habilitar Wayland para Firefox + +```nix +# ... + env = [ + "SDL_VIDEODRIVER, wayland" + "MOZ_ENABLE_WAYLAND, 1" + ]; +# ... +``` + +--- + +### `gestures.nix` — Gestos del touchpad + +Ubicación: `modules/home/hyprland/gestures.nix` + +Ejemplo: Desactivar deslizamiento entre espacios + +```nix +# ... + gestures = { + workspace_swipe = 0; + }; +# ... +``` + +--- + +### `misc.nix` — Ajustes varios + +Ubicación: `modules/home/hyprland/misc.nix` + +Ejemplo: Activar Frecuencia de Actualización Variable (VRR) + +```nix +# ... + misc = { + vrr = 1; + }; +# ... +``` + +--- + +### `hyprland.nix` — Configuración principal + +Ubicación: `modules/home/hyprland/hyprland.nix` + +Ejemplo: Distribución del teclado + +```nix +# ... + input = { + kb_layout = "us"; + }; +# ... +``` + +--- + +### `windowrules.nix` — Reglas de ventanas + +Ubicación: `modules/home/hyprland/windowrules.nix` + +Ejemplo: Hacer que Thunar flote siempre + +```nix +# ... + windowrule = [ + "float, class:^(foot-floating)$" + "float, class:^(Thunar)$" + ]; +# ... +``` + +--- + +## Consejos útiles + +- Realiza un cambio a la vez y recompila para validar. +- Mantén una terminal abierta mientras experimentas por si cambias el atajo del lanzador. +- Si algo se rompe, reinicia y elige una generación anterior en el menú de arranque. + diff --git a/cheatsheets/hyprland-customization-guide.md b/cheatsheets/hyprland-customization-guide.md index 529917f..a6dc93d 100644 --- a/cheatsheets/hyprland-customization-guide.md +++ b/cheatsheets/hyprland-customization-guide.md @@ -1,302 +1,163 @@ -# A Guide to Customizing Hyprland in ddubsOS +# A Guide to Customizing Hyprland in ZaneyOS -This guide provides a more detailed look at how to customize your Hyprland experience in ddubsOS. We'll go through the most important configuration files, explaining what they do and how you can edit them. +This guide provides a practical overview for customizing your Hyprland experience in ZaneyOS. We’ll cover the most relevant files, what they do, and small, safe edits you can make. -**A Word of Caution:** The configuration files are written in the Nix language. Nix has a very specific syntax, and any mistakes can prevent your system from building successfully. Always be careful when editing these files, and make sure to follow the examples closely. +Note: These files are written in Nix. A small syntax error can break builds. Make one change at a time and keep your edits under version control. -## Applying Your Changes +## Applying your changes -After making any changes to these files, you'll need to apply them. Open a terminal and run: +Preferred (ZaneyOS-specific): +- `zcli rebuild` + - Note: The `fr` alias is deprecated. -```bash -zcli rebuild -``` - -This command will rebuild your system with the new configuration. If there are any errors in your configuration, this command will fail. +Manual backup method (works anywhere): +- From the repo root, replace PROFILE with your profile (intel, nvidia, nvidia-laptop, vm): + - `sudo nixos-rebuild switch --flake .#PROFILE` --- -### `binds.nix` - Keybindings +### `binds.nix` — Keybindings -This file controls all of your keyboard and mouse shortcuts in Hyprland. +Controls keyboard and mouse shortcuts. -**Location:** `modules/home/hyprland/binds.nix` +Location: `modules/home/hyprland/binds.nix` -You can change existing keybindings or add new ones. The format is a string with comma-separated values: `MODIFIER, KEY, DISPATCHER, VALUE`. +Format: `MODIFIER, KEY, DISPATCHER, VALUE` -**Example:** - -Let's say you want to change the keybinding for opening a terminal from `SUPER + Return` to `SUPER + T`. - -**Original:** +Example: Change terminal from Super+Return to Super+T ```nix # ... - bind = [ - # ... - "$modifier,Return,exec, ${terminal}" - # ... - ]; -# ... -``` - -**Modified:** - -```nix -# ... - bind = [ - # ... - "$modifier,T,exec, ${terminal}" - # ... - ]; + bind = [ + # ... + "$modifier,T,exec, ${terminal}" + # ... + ]; # ... ``` --- -### `exec-once.nix` - Startup Applications +### `exec-once.nix` — Startup applications -This file lists the applications and commands that run automatically when you start Hyprland. +Commands that start automatically with Hyprland. -**Location:** `modules/home/hyprland/exec-once.nix` +Location: `modules/home/hyprland/exec-once.nix` -You can add or remove commands from this list. Each command is a string. - -**Example:** - -If you want to start the `copyq` application every time you log in, you can add it to the list. - -**Original:** +Example: Add copyq to autostart ```nix # ... - exec-once = [ - # ... - "pypr &" # pyprland for drop down term SUPERSHIFT + T - ]; -# ... -``` - -**Modified:** - -```nix -# ... - exec-once = [ - # ... - "pypr &" # pyprland for drop down term SUPERSHIFT + T - "copyq" - ]; + exec-once = [ + # ... + "pypr &" + "copyq" + ]; # ... ``` --- -### `decoration.nix` - Window Decorations +### `decoration.nix` — Borders, shadows, blur -This file controls the appearance of window borders, shadows, and blur effects. +Location: `modules/home/hyprland/decoration.nix` -**Location:** `modules/home/hyprland/decoration.nix` - -You can change values like `rounding` for rounded corners, or adjust the `blur` and `shadow` settings. - -**Example:** - -To increase the rounding of window corners from `0` to `10`. - -**Original:** +Example: Rounded corners ```nix # ... - decoration = { - rounding = 0; -# ... -``` - -**Modified:** - -```nix -# ... - decoration = { - rounding = 10; + decoration = { + rounding = 10; + }; # ... ``` --- -### `env.nix` - Environment Variables +### `env.nix` — Environment variables -This file sets environment variables for your Hyprland session. These can affect how applications behave. +Location: `modules/home/hyprland/env.nix` -**Location:** `modules/home/hyprland/env.nix` - -You can add or change environment variables in this list. - -**Example:** - -To set the `MOZ_ENABLE_WAYLAND` variable to `1`, which forces Firefox to run in Wayland mode. - -**Original:** +Example: Enable Wayland for Firefox ```nix # ... - env = [ - # ... - "SDL_VIDEODRIVER, wayland" - # ... - ]; -# ... -``` - -**Modified:** - -```nix -# ... - env = [ - # ... - "SDL_VIDEODRIVER, wayland" - "MOZ_ENABLE_WAYLAND, 1" - # ... - ]; + env = [ + "SDL_VIDEODRIVER, wayland" + "MOZ_ENABLE_WAYLAND, 1" + ]; # ... ``` --- -### `gestures.nix` - Touchpad Gestures +### `gestures.nix` — Touchpad gestures -This file controls touchpad gestures, like swiping between workspaces. +Location: `modules/home/hyprland/gestures.nix` -**Location:** `modules/home/hyprland/gestures.nix` - -You can enable or disable gestures and change their behavior. - -**Example:** - -To disable workspace swiping. - -**Original:** +Example: Disable workspace swipe ```nix # ... - gestures = { - workspace_swipe = 1; -# ... -``` - -**Modified:** - -```nix -# ... - gestures = { - workspace_swipe = 0; + gestures = { + workspace_swipe = 0; + }; # ... ``` --- -### `misc.nix` - Miscellaneous Settings +### `misc.nix` — Misc settings -This file contains various settings that don't fit into the other categories. +Location: `modules/home/hyprland/misc.nix` -**Location:** `modules/home/hyprland/misc.nix` - -You can change settings like `vrr` (Variable Refresh Rate) or `disable_hyprland_logo`. - -**Example:** - -To enable Variable Refresh Rate. - -**Original:** +Example: Enable Variable Refresh Rate ```nix # ... - misc = { - # ... - vrr = 0; - # ... - }; -# ... -``` - -**Modified:** - -```nix -# ... - misc = { - # ... - vrr = 1; - # ... - }; + misc = { + vrr = 1; + }; # ... ``` --- -### `hyprland.nix` - Main Configuration +### `hyprland.nix` — Main configuration -This is the main Hyprland configuration file. It sets up general settings, input devices, and the window layout. +Location: `modules/home/hyprland/hyprland.nix` -**Location:** `modules/home/hyprland/hyprland.nix` - -You can change things like the keyboard layout, touchpad settings, and the layout engine. - -**Example:** - -To change the keyboard layout from the default to `us`. - -**Original:** +Example: Keyboard layout ```nix # ... - input = { - kb_layout = "${keyboardLayout}"; -# ... -``` - -**Modified:** - -```nix -# ... - input = { - kb_layout = "us"; + input = { + kb_layout = "us"; + }; # ... ``` --- -### `windowrules.nix` - Window Rules +### `windowrules.nix` — Window rules -This file defines rules for how specific windows should behave. You can make certain applications always float, open on a specific workspace, or have a certain opacity. +Location: `modules/home/hyprland/windowrules.nix` -**Location:** `modules/home/hyprland/windowrules.nix` - -You can add new rules to the `windowrule` list. - -**Example:** - -To make the `thunar` file manager always float. - -**Original:** +Example: Float Thunar always ```nix # ... - windowrule = [ - # ... - "float, class:^(foot-floating)$" - # ... - ]; + windowrule = [ + "float, class:^(foot-floating)$" + "float, class:^(Thunar)$" + ]; # ... ``` -**Modified:** +--- -```nix -# ... - windowrule = [ - # ... - "float, class:^(foot-floating)$" - "float, class:^(Thunar)$" - # ... - ]; -# ... -``` +## Helpful tips + +- Make one change at a time and rebuild to validate. +- Keep a terminal open during experiments in case your launcher keybind changes. +- If something breaks, reboot and choose a previous generation in the boot menu. diff --git a/cheatsheets/nix-beginner-guide.es.md b/cheatsheets/nix-beginner-guide.es.md new file mode 100644 index 0000000..3ec70b1 --- /dev/null +++ b/cheatsheets/nix-beginner-guide.es.md @@ -0,0 +1,67 @@ +# Guía para Principiantes de ZaneyOS: Personalización Básica + +¡Bienvenido! Esta guía es para quienes son nuevos en Nix y quieren realizar personalizaciones comunes y seguras en su instalación de ZaneyOS. Mantendremos todo simple y al grano. + +## Diseño del repositorio (dónde cambiar las cosas) + +- `flake.nix`: Punto de entrada del sistema. Normalmente no necesitas editarlo para ajustes cotidianos. +- `hosts/`: Configuración por máquina. + - `hosts//` + - `variables.nix`: Tu panel principal (activar/desactivar funciones, establecer opciones). + - `host-packages.nix`: Paquetes extra solo para esta máquina. +- `modules/`: Bloques reutilizables para el sistema y Home Manager. + - `modules/core/global-packages.nix`: Paquetes instalados en todas las máquinas. + - `modules/home/hyprland/binds.nix`: Atajos de Hyprland. + +## Instalar paquetes + +Dos patrones comunes: + +### 1) Solo en esta máquina +Edita `hosts//host-packages.nix` y añade el nombre del paquete: + +```nix +[ + brave + (catppuccin-vsc.override { + variant = "mocha"; + }) + cowsay +] +``` + +### 2) En todas las máquinas +Edita `modules/core/global-packages.nix` y añade el paquete a la lista. + +## Ajustes de monitores (por host) + +Edita `hosts//variables.nix` y define la(s) línea(s) extra del monitor: + +```nix +# Ejemplo: 1080p a 144 Hz en DP-1 +extraMonitorSettings = "monitor=DP-1,1920x1080@144"; +``` + +## Cambiar atajos de Hyprland + +Edita `modules/home/hyprland/binds.nix`. Por ejemplo, cambiar la terminal de Super+Return a Super+T: + +```nix +"SUPER, T, exec, ${terminal}" +``` + +## Aplicar y probar tus cambios + +Preferido (específico de ZaneyOS): +- `zcli rebuild` + - Nota: el alias `fr` está obsoleto. + +Método manual de respaldo (funciona en cualquier instalación): +- Desde la raíz del repo, reemplaza PROFILE por tu perfil (intel, nvidia, nvidia-laptop, vm): + - `sudo nixos-rebuild switch --flake .#PROFILE` + +Consejos +- Si un rebuild falla, lee el error cerca del final: suele apuntar al archivo/línea exacta. +- Si un cambio rompe tu sesión tras reiniciar, elige una “generación” anterior en el menú de arranque. +- Usa Git para versionar tus cambios y poder revertir fácilmente. + diff --git a/cheatsheets/nix-beginner-guide.md b/cheatsheets/nix-beginner-guide.md index 01308b9..cc88d20 100644 --- a/cheatsheets/nix-beginner-guide.md +++ b/cheatsheets/nix-beginner-guide.md @@ -1,101 +1,66 @@ -# Welcome to ddubsOS! A Beginner's Guide to Customization +# ZaneyOS Beginner’s Guide to Customization -Welcome! This guide is for users who are new to Nix and want to make some common customizations to their ddubsOS setup. We'll keep it simple and focus on the essentials. +Welcome! This guide is for users who are new to Nix and want to make common, safe customizations to their ZaneyOS setup. We’ll keep it simple and focus on essentials. -## Understanding the Layout +## Repository layout (where to change things) -NixOS configurations can seem complex, but for day-to-day changes, you only need to know about a few key files and directories. +- `flake.nix`: Entry point for the whole system. You generally don’t need to edit this for day‑to‑day tweaks. +- `hosts/`: Per‑machine configuration. + - `hosts//` + - `variables.nix`: Your main control panel (enable/disable features, set options). + - `host-packages.nix`: Extra packages only for this one machine. +- `modules/`: Reusable building blocks for the system and Home Manager. + - `modules/core/global-packages.nix`: Packages installed on all machines. + - `modules/home/hyprland/binds.nix`: Hyprland keybindings. -- `flake.nix`: This is the main file for the entire system. You shouldn't need to edit this file directly for most common changes. -- `hosts/`: This directory contains the configuration for each individual computer (or "host") you've installed ddubsOS on. - - `hosts//`: This is where you'll make most of your changes. - - `variables.nix`: This is your main control panel. You can enable/disable features, change settings, and more. - - `host-packages.nix`: This is where you can add packages that you only want on this specific computer. -- `modules/`: This directory contains the bulk of the configuration, broken down into smaller, reusable pieces ("modules"). - - `modules/core/global-packages.nix`: You can add packages here if you want them to be installed on *all* of your ddubsOS computers. - - `modules/home/hyprland/binds.nix`: This is where you can customize your Hyprland keybindings. +## Installing packages -## How to Add Packages +Two common patterns: -There are two main ways to add packages: +### 1) Only on this machine +Edit `hosts//host-packages.nix` and add the package name: -### 1. For a Single Computer +```nix +[ + brave + (catppuccin-vsc.override { + variant = "mocha"; + }) + cowsay +] +``` -If you only want to install a package on your current computer, you'll add it to `hosts//host-packages.nix`. +### 2) On all machines +Edit `modules/core/global-packages.nix` and add the package to the list. -1. Open `hosts//host-packages.nix` in your favorite editor. -2. You'll see a list of packages. Simply add the name of the package you want to install to the list. For example, to add the `cowsay` package, you would change this: +## Monitor settings (per host) - ```nix - [ - brave - (catppuccin-vsc.override { - variant = "mocha"; - }) - ] - ``` +Edit `hosts//variables.nix` and set the extra monitor line(s): - to this: +```nix +# Example: 1080p at 144 Hz on DP-1 +extraMonitorSettings = "monitor=DP-1,1920x1080@144"; +``` - ```nix - [ - brave - (catppuccin-vsc.override { - variant = "mocha"; - }) - cowsay - ] - ``` +## Change Hyprland keybindings -3. Save the file. +Edit `modules/home/hyprland/binds.nix`. For example, change terminal from Super+Return to Super+T: -### 2. For All Computers +```nix +"SUPER, T, exec, ${terminal}" +``` -If you want a package to be installed on every computer you use ddubsOS on, you'll add it to `modules/core/global-packages.nix`. The process is the same as above. +## Apply and test your changes -## How to Change Monitor Settings +Preferred (ZaneyOS-specific): +- `zcli rebuild` + - Note: The `fr` alias is deprecated. -You can change your monitor settings in `hosts//variables.nix`. +Manual backup method (works anywhere): +- From the repo root, replace PROFILE with your profile (intel, nvidia, nvidia-laptop, vm): + - `sudo nixos-rebuild switch --flake .#PROFILE` -1. Open `hosts//variables.nix`. -2. Look for the `extraMonitorSettings` line. -3. You can add your monitor settings here. For example, to set the resolution and refresh rate for a monitor named `DP-1`, you would change this: - - ```nix - extraMonitorSettings = ""; - ``` - - to this: - - ```nix - extraMonitorSettings = "monitor=DP-1,1920x1080@144"; - ``` - -4. Save the file. - -## How to Change Hyprland Bindings - -You can change your Hyprland keybindings in `modules/home/hyprland/binds.nix`. - -1. Open `modules/home/hyprland/binds.nix`. -2. You'll see a list of keybindings. You can change them to your liking. For example, to change the keybinding for opening a terminal from `SUPER, Return` to `SUPER, T`, you would change this: - - ```nix - "SUPER, Return, exec, ${terminal}" - ``` - - to this: - - ```nix - "SUPER, T, exec, ${terminal}" - ``` - -3. Save the file. - -## Applying Your Changes - -After you've made any changes, you need to apply them. - -1. Open a terminal. -2. Run the command `zcli rebuild`. This will apply your changes to the system. -3. If the command completes successfully, your changes are now active! Some changes may require a reboot to take effect. +Tips +- If a rebuild fails, read the error near the bottom of the output—it usually points to the exact file/line. +- If a change breaks your session after a reboot, pick an older “generation” from the boot menu to roll back. +- Use Git to track your edits so you can revert easily. From 4a4514d38dc9e0a8728754453eff1cea5b37733a Mon Sep 17 00:00:00 2001 From: Don Williams Date: Sun, 31 Aug 2025 23:33:15 -0400 Subject: [PATCH 05/18] Upd bindings SUPERSHIFT + C to edit On branch stable-2.4 Your branch is up to date with 'origin/stable-2.4'. Changes to be committed: modified: FAQ.es.md modified: FAQ.md modified: cheatsheets/hyprland/hyprland.binds.cheatsheet.md --- FAQ.es.md | 4 ++-- FAQ.md | 4 ++-- cheatsheets/hyprland/hyprland.binds.cheatsheet.md | 1 + 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/FAQ.es.md b/FAQ.es.md index 69c4242..f8fed2f 100644 --- a/FAQ.es.md +++ b/FAQ.es.md @@ -2,8 +2,8 @@ # 💬 Preguntas frecuentes de ZaneyOS para v2.4 -- **Revisión v1.25** -- **Fecha:** 23-agosto-2025 +- **Revisión v1.26** +- **Fecha:** 1-septiembre-2025 > IMPORTANTE: ¿Actualizando de v2.3 a v2.4? > - Altamente recomendado: Lee `ZaneyOS-Upgrade.md` completamente antes de intentar la actualización. diff --git a/FAQ.md b/FAQ.md index ed3c66d..4e7e26b 100644 --- a/FAQ.md +++ b/FAQ.md @@ -2,8 +2,8 @@ # 💬 ZaneyOS FAQ for v2.4 -- **Revision v1.25** -- **Date:** 23-August-2025 +- **Revision v1.26** +- **Date:** 01-September-2025 > IMPORTANT: Upgrading from v2.3 to v2.4? > - Strongly recommended: Read `ZaneyOS-Upgrade.md` fully before attempting the upgrade. diff --git a/cheatsheets/hyprland/hyprland.binds.cheatsheet.md b/cheatsheets/hyprland/hyprland.binds.cheatsheet.md index 5f8f4dd..c024232 100644 --- a/cheatsheets/hyprland/hyprland.binds.cheatsheet.md +++ b/cheatsheets/hyprland/hyprland.binds.cheatsheet.md @@ -50,6 +50,7 @@ - SUPERKEY+F — Fullscreen - SUPERKEY+SHIFT+F — Toggle floating - SUPERKEY+ALT+F — Workspace option: allfloat +- SUPERKEY+SHIFT+C — Exit Hyprland - SUPERKEY+SPACE — Toggle floating - SUPERKEY+SHIFT+SPACE — Workspace option: allfloat - SUPERKEY+SHIFT+M — swap_layout From 14a79167bd288db57c1b4d6d1c7322323f274223 Mon Sep 17 00:00:00 2001 From: Don Williams Date: Tue, 9 Sep 2025 13:38:15 -0400 Subject: [PATCH 06/18] Add defensive code for invalid hostname On branch stable-2.4 Your branch is up to date with 'origin/stable-2.4'. Changes to be committed: modified: install-zaneyos.sh modified: modules/core/network.nix --- install-zaneyos.sh | 56 ++++++++++++++++++++++++++++++++++++++++ modules/core/network.nix | 8 ++++++ 2 files changed, 64 insertions(+) diff --git a/install-zaneyos.sh b/install-zaneyos.sh index cffc0fd..f8c74b8 100755 --- a/install-zaneyos.sh +++ b/install-zaneyos.sh @@ -18,6 +18,43 @@ LOG_FILE="${LOG_DIR}/install_$(date +"%Y-%m-%d_%H-%M-%S").log" mkdir -p "$LOG_DIR" exec > >(tee -a "$LOG_FILE") 2>&1 +# Hostname validation and sanitization helpers +HOSTNAME_REGEX='^[[:alnum:]]([[:alnum:]_-]{0,61}[[:alnum:]])?$' + +is_valid_hostname() { + local hn="$1" + [[ "$hn" =~ $HOSTNAME_REGEX ]] +} + +sanitize_hostname() { + local hn="$1" + # Lowercase + hn=$(printf '%s' "$hn" | tr '[:upper:]' '[:lower:]') + # Replace invalid chars (including dots/spaces) with '-' + hn=$(printf '%s' "$hn" | sed -E 's/[^[:alnum:]_-]+/-/g') + # Collapse consecutive - or _ to a single - + hn=$(printf '%s' "$hn" | sed -E 's/[-_]{2,}/-/g') + # Trim leading/trailing non-alnum + hn=$(printf '%s' "$hn" | sed -E 's/^[^[:alnum:]]+//; s/[^[:alnum:]]+$//') + # Truncate to 63 characters (hostname label limit) + hn=${hn:0:63} + # Ensure start/end are alnum in case truncation left a non-alnum at edges + hn=$(printf '%s' "$hn" | sed -E 's/^[^[:alnum:]]+//; s/[^[:alnum:]]+$//') + printf '%s' "$hn" +} + +ensure_safe_hostname() { + # Usage: ensure_safe_hostname + local input="$1"; local def="$2" + local candidate="$input" + if [ -z "$candidate" ]; then candidate="$def"; fi + local sanitized + sanitized=$(sanitize_hostname "$candidate") + if [ -z "$sanitized" ]; then sanitized="$def"; fi + if ! is_valid_hostname "$sanitized"; then return 1; fi + printf '%s' "$sanitized" +} + # Function to print a section header print_header() { echo -e "${GREEN}╔═══════════════════════════════════════════════════════════════════════╗${NC}" @@ -109,6 +146,25 @@ if [ "$hostName" = "default" ]; then fi fi +# Validate and sanitize hostname to meet NixOS constraints +safeHost=$(ensure_safe_hostname "$hostName" "my-desktop") +if [ "$safeHost" != "$hostName" ]; then + echo -e "${RED}The hostname '$hostName' is not compliant (letters, numbers, '-', '_' only; 1-63 chars; start/end alnum).${NC}" + echo -e "It will be adjusted to: ${GREEN}$safeHost${NC}" + read -p "Use '$safeHost'? (Y/n): " -n 1 -r; echo + if [[ $REPLY =~ ^[Nn]$ ]]; then + read -rp "Enter a hostname (letters, numbers, hyphens/underscores; 1-63 chars): " hostName + safeHost=$(ensure_safe_hostname "$hostName" "my-desktop") + fi +fi + +if ! is_valid_hostname "$safeHost"; then + print_error "Hostname '$hostName' is invalid even after sanitization." + echo "Please rerun and choose a compliant hostname (letters, numbers, hyphens, underscores; 1-63 chars, start/end alphanumeric)." + exit 1 +fi + +hostName="$safeHost" echo -e "${GREEN}✓ Hostname set to: $hostName${NC}" print_header "GPU Profile Detection" diff --git a/modules/core/network.nix b/modules/core/network.nix index 132d9bc..e6f0b59 100644 --- a/modules/core/network.nix +++ b/modules/core/network.nix @@ -7,6 +7,14 @@ let inherit (import ../../hosts/${host}/variables.nix) hostId; in { + # Defensive assertion for hostname validity (clearer message at eval time) + assertions = [ + { + assertion = builtins.match "^[[:alnum:]]([[:alnum:]_-]{0,61}[[:alnum:]])?$" host != null; + message = "Invalid hostname '${host}'. Must be 1-63 chars, start/end alphanumeric; allowed middle chars: letters, digits, '-' or '_'."; + } + ]; + networking = { hostName = "${host}"; hostId = hostId; From 1ecaadcada6366e9b1cccc6adda575e69842b44c Mon Sep 17 00:00:00 2001 From: dwilliams Date: Tue, 9 Sep 2025 13:57:23 -0400 Subject: [PATCH 07/18] Added new stable 24 test host --- flake.nix | 4 +- zaneyos-24-vm/default.nix | 6 ++ zaneyos-24-vm/hardware.nix | 45 +++++++++++++ zaneyos-24-vm/host-packages.nix | 7 ++ zaneyos-24-vm/variables.nix | 110 ++++++++++++++++++++++++++++++++ 5 files changed, 170 insertions(+), 2 deletions(-) create mode 100644 zaneyos-24-vm/default.nix create mode 100644 zaneyos-24-vm/hardware.nix create mode 100644 zaneyos-24-vm/host-packages.nix create mode 100644 zaneyos-24-vm/variables.nix diff --git a/flake.nix b/flake.nix index 417408e..c88f2b5 100644 --- a/flake.nix +++ b/flake.nix @@ -30,8 +30,8 @@ }@inputs: let system = "x86_64-linux"; - host = "zaneyos-oem"; - profile = "vm"; + host = "zaneyos-24-vm"; + profile = "vm"; username = "dwilliams"; # Deduplicate nixosConfigurations while preserving the top-level 'profile' diff --git a/zaneyos-24-vm/default.nix b/zaneyos-24-vm/default.nix new file mode 100644 index 0000000..1ef7d77 --- /dev/null +++ b/zaneyos-24-vm/default.nix @@ -0,0 +1,6 @@ +{ ... }: { + imports = [ + ./hardware.nix + ./host-packages.nix + ]; +} diff --git a/zaneyos-24-vm/hardware.nix b/zaneyos-24-vm/hardware.nix new file mode 100644 index 0000000..e8914eb --- /dev/null +++ b/zaneyos-24-vm/hardware.nix @@ -0,0 +1,45 @@ +# Do not modify this file! It was generated by ‘nixos-generate-config’ +# and may be overwritten by future invocations. Please make changes +# to /etc/nixos/configuration.nix instead. +{ config, lib, pkgs, modulesPath, ... }: + +{ + imports = + [ (modulesPath + "/profiles/qemu-guest.nix") + ]; + + boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ "kvm-intel" ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/e5fc1006-4d0b-41db-8c43-22b3cb8110c6"; + fsType = "ext4"; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/9287-3738"; + fsType = "vfat"; + options = [ "fmask=0077" "dmask=0077" ]; + }; + + fileSystems."/mnt/nas" = + { device = "192.168.40.11:/volume1/DiskStation54TB"; + fsType = "nfs"; + }; + + swapDevices = + [ { device = "/dev/disk/by-uuid/a6e9dd8b-6767-44f4-84fa-30d02d90d087"; } + ]; + + # Enables DHCP on each ethernet and wireless interface. In case of scripted networking + # (the default) this is the recommended approach. When using systemd-networkd it's + # still possible to use this option, but it's recommended to use it in conjunction + # with explicit per-interface declarations with `networking.interfaces..useDHCP`. + networking.useDHCP = lib.mkDefault true; + # networking.interfaces.docker0.useDHCP = lib.mkDefault true; + # networking.interfaces.ens18.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; +} diff --git a/zaneyos-24-vm/host-packages.nix b/zaneyos-24-vm/host-packages.nix new file mode 100644 index 0000000..f44b200 --- /dev/null +++ b/zaneyos-24-vm/host-packages.nix @@ -0,0 +1,7 @@ +{pkgs, ...}: { + environment.systemPackages = with pkgs; [ + audacity + discord + nodejs + ]; +} diff --git a/zaneyos-24-vm/variables.nix b/zaneyos-24-vm/variables.nix new file mode 100644 index 0000000..d177f37 --- /dev/null +++ b/zaneyos-24-vm/variables.nix @@ -0,0 +1,110 @@ +{ + # Git Configuration ( For Pulling Software Repos ) + gitUsername = "dwilliams"; + gitEmail = "don.e.williams@gmail.com"; + + # Set Displau Manager + # `tui` for Text login + # `sddm` for graphical GUI (default) + # SDDM background is set with stylixImage + displayManager = "sddm"; + + # Emable/disable bundled applications + tmuxEnable = false; + alacrittyEnable = false; + weztermEnable = false; + ghosttyEnable = false; + vscodeEnable = false; + # Note: This is evil-helix with VIM keybindings by default + helixEnable = false; + #To install: Enable here, zcli rebuild, then run zcli doom install + doomEmacsEnable = false; + + # Hyprland Settings + # Examples: + # extraMonitorSettings = "monitor = Virtual-1,1920x1080@60,auto,1"; + # extraMonitorSettings = "monitor = HDMI-A-1,1920x1080@60,auto,1"; + # You can configure multiple monitors. + # Inside the quotes, create a new line for each monitor. + extraMonitorSettings = " + + "; + + # Waybar Settings + clock24h = false; + + # Program Options + # Set Default Browser (google-chrome-stable for google-chrome) + # This does NOT install your browser + # You need to install it by adding it to the `packages.nix` + # or as a flatpak + browser = "brave"; + + # Available Options: + # Kitty, ghostty, wezterm, aalacrity + # Note: kitty, wezterm, alacritty have to be enabled in `variables.nix` + # Setting it here does not enable it. Kitty is installed by default + terminal = "kitty"; # Set Default System Terminal + + keyboardLayout = "us"; + consoleKeyMap = "us"; + + # For Nvidia Prime support + intelID = "PCI:1:0:0"; + nvidiaID = "PCI:0:2:0"; + + # Enable NFS + enableNFS = true; + + # Enable Printing Support + printEnable = false; + + # Enable Thunar GUI File Manager + # Yazi is default File Manager + thunarEnable = false; + + # Themes, waybar and animation. + # Only uncomment your selection + # The others much be commented out. + + # Set Stylix Image + # This will set your color palette + # Default background + # Add new images to ~/zaneyos/wallpapers + stylixImage = ../../wallpapers/mountainscapedark.jpg; + #stylixImage = ../../wallpapers/AnimeGirlNightSky.jpg; + #stylixImage = ../../wallpapers/Anime-Purple-eyes.png; + #stylixImage = ../../wallpapers/Rainnight.jpg; + #stylixImage = ../../wallpapers/zaney-wallpaper.jpg; + #stylixImage = ../../wallpapers/nix-wallpapers-strips-logo.jpg; + #stylixImage = ../../wallpapers/beautifulmountainscape.jpg; + + # Set Waybar + # Available Options: + #waybarChoice = ../../modules/home/waybar/waybar-curved.nix; + #waybarChoice = ../../modules/home/waybar/waybar-ddubs.nix; + #waybarChoice = ../../modules/home/waybar/waybar-ddubs-2.nix; + #waybarChoice = ../../modules/home/waybar/waybar-simple.nix; + # Throwback to ZaneyOS v1.0 + #waybarChoice = ../../modules/home/waybar/waybar-jerry.nix; + # Very colorful and bright colors + #waybarChoice = ../../modules/home/waybar/waybar-nekodyke.nix; + # DWM styled waybars from Matt at TheLinuxCast + #waybarChoice = ../../modules/home/waybar/waybar-dwm.nix; + waybarChoice = ../../modules/home/waybar/waybar-dwm-2.nix; + + # Set Animation style + # Available options are: + # animations-def.nix (default) + # animations-end4.nix (end-4 project very fluid) + # animations-dynamic.nix (ml4w project) + # animations-moving.nix (ml4w project) + #animChoice = ../../modules/home/hyprland/animations-def.nix; + #animChoice = ../../modules/home/hyprland/animations-end4.nix; + animChoice = ../../modules/home/hyprland/animations-dynamic.nix; + #animChoice = ../../modules/home/hyprland/animations-moving.nix; + + # Set network hostId if required (needed for zfs) + # Otherwise leave as-is + hostId = "5ab03f50"; +} From eb95c2cbed86951ac0b0bf186f9c31bc6378e10c Mon Sep 17 00:00:00 2001 From: dwilliams Date: Tue, 9 Sep 2025 13:59:21 -0400 Subject: [PATCH 08/18] Added waypaper --- modules/core/packages.nix | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/core/packages.nix b/modules/core/packages.nix index 4c9fc35..5e35dd4 100644 --- a/modules/core/packages.nix +++ b/modules/core/packages.nix @@ -32,12 +32,10 @@ # Hyprland systeminfo QT (Optional) #inputs.hyprsysteminfo.packages.${pkgs.system}.default - #aider-chat # AI in terminal (Optional: Client only) amfora # Fancy Terminal Browser For Gemini Protocol appimage-run # Needed For AppImage Support brave # Brave Browser brightnessctl # For Screen Brightness Control - #claude-code # Claude code terminal AI (Optional: Client only) cliphist # Clipboard manager using rofi menu cmatrix # Matrix Movie Effect In Terminal cowsay # Great Fun Terminal Program @@ -79,6 +77,7 @@ usbutils # Good Tools For USB Devices uwsm # Universal Wayland Session Manager (optional must be enabled) v4l-utils # Used For Things Like OBS Virtual Camera + waypaper # wallpaper changer warp-terminal # Terminal with AI support build in wget # Tool For Fetching Files With Links ytmdl # Tool For Downloading Audio From YouTube From d514be0546fdd3b71beefc9a3aa22cb7c89f25ad Mon Sep 17 00:00:00 2001 From: dwilliams Date: Tue, 9 Sep 2025 14:00:24 -0400 Subject: [PATCH 09/18] Added waypaper --- {zaneyos-24-vm => hosts/zaneyos-24-vm}/default.nix | 0 {zaneyos-24-vm => hosts/zaneyos-24-vm}/hardware.nix | 0 {zaneyos-24-vm => hosts/zaneyos-24-vm}/host-packages.nix | 0 {zaneyos-24-vm => hosts/zaneyos-24-vm}/variables.nix | 0 4 files changed, 0 insertions(+), 0 deletions(-) rename {zaneyos-24-vm => hosts/zaneyos-24-vm}/default.nix (100%) rename {zaneyos-24-vm => hosts/zaneyos-24-vm}/hardware.nix (100%) rename {zaneyos-24-vm => hosts/zaneyos-24-vm}/host-packages.nix (100%) rename {zaneyos-24-vm => hosts/zaneyos-24-vm}/variables.nix (100%) diff --git a/zaneyos-24-vm/default.nix b/hosts/zaneyos-24-vm/default.nix similarity index 100% rename from zaneyos-24-vm/default.nix rename to hosts/zaneyos-24-vm/default.nix diff --git a/zaneyos-24-vm/hardware.nix b/hosts/zaneyos-24-vm/hardware.nix similarity index 100% rename from zaneyos-24-vm/hardware.nix rename to hosts/zaneyos-24-vm/hardware.nix diff --git a/zaneyos-24-vm/host-packages.nix b/hosts/zaneyos-24-vm/host-packages.nix similarity index 100% rename from zaneyos-24-vm/host-packages.nix rename to hosts/zaneyos-24-vm/host-packages.nix diff --git a/zaneyos-24-vm/variables.nix b/hosts/zaneyos-24-vm/variables.nix similarity index 100% rename from zaneyos-24-vm/variables.nix rename to hosts/zaneyos-24-vm/variables.nix From c91e5108cdd05bb60416494b98906cf787e79635 Mon Sep 17 00:00:00 2001 From: dwilliams Date: Tue, 9 Sep 2025 14:15:13 -0400 Subject: [PATCH 10/18] Adde SUPER + R for rofi menu inc font sz on waybar On branch stable-2.4 Your branch is up to date with 'origin/stable-2.4'. Changes to be committed: modified: modules/home/hyprland/binds.nix modified: modules/home/waybar/waybar-dwm-2.nix --- modules/home/hyprland/binds.nix | 1 + modules/home/waybar/waybar-dwm-2.nix | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/home/hyprland/binds.nix b/modules/home/hyprland/binds.nix index 3efa265..025cb08 100644 --- a/modules/home/hyprland/binds.nix +++ b/modules/home/hyprland/binds.nix @@ -12,6 +12,7 @@ in "$modifier,Return,exec,${terminal}" "$modifier,K,exec,list-keybinds" "$modifier SHIFT,Return,exec,rofi-launcher" + "$modifier ,R,exec,rofi-launcher" "$modifier SHIFT,W,exec,web-search" "$modifier ALT,W,exec,wallsetter" "$modifier SHIFT,N,exec,swaync-client -rs" diff --git a/modules/home/waybar/waybar-dwm-2.nix b/modules/home/waybar/waybar-dwm-2.nix index 202d152..862f609 100644 --- a/modules/home/waybar/waybar-dwm-2.nix +++ b/modules/home/waybar/waybar-dwm-2.nix @@ -199,7 +199,7 @@ margin: 0; padding: 0; font-family: "JetBrains Mono Nerd Font"; - font-size: 10pt; + font-size: 14pt; font-weight: 700; padding-bottom: 0px; } From 9fa575b8f96aa0b3f33261a01dabfccaff1c1f4d Mon Sep 17 00:00:00 2001 From: Don Williams Date: Tue, 9 Sep 2025 17:47:36 -0400 Subject: [PATCH 11/18] docs(changelog): add hostname validation/sanitization fix and update revision date Installer: validate and sanitize hostnames; reject 'default'; prompt to accept sanitized value.\nNix: add assertion in modules/core/network.nix for clearer error on invalid hostnames.\nPrevents Nix evaluation failures on networking.hostName (e.g., dots in hostname). --- CHANGELOG.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4a62a2e..9ec7a97 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,14 @@ # 🚀 **Current Release - ZaneyOS v2.4** +#### 📅 **Updated: September 9th, 2025** + +- 🛡️ Installer: Added defensive hostname validation and sanitization + - Prevents invalid hostnames (e.g., with dots) from causing Nix evaluation errors + - Auto-sanitizes to a compliant hostname (letters/digits with '-' or '_', 1–63 chars) and prompts for confirmation + - Explicitly rejects 'default' to avoid template overwrites +- 🧩 Nix: Added assertion in modules/core/network.nix for clearer errors if an invalid hostname is provided + #### 📅 **Updated: August 30th, 2025** - Merged `dev` branch to `main` in preparation of v2.4 release From 125e3ab71fec5212315de2b59a2844343f34368d Mon Sep 17 00:00:00 2001 From: dwilliam62 Date: Fri, 12 Sep 2025 17:28:01 +0000 Subject: [PATCH 12/18] Edit vm-guest-services.nix build failure when enabled with incompatible neon version --- modules/drivers/vm-guest-services.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/drivers/vm-guest-services.nix b/modules/drivers/vm-guest-services.nix index d3e0555..d14229d 100644 --- a/modules/drivers/vm-guest-services.nix +++ b/modules/drivers/vm-guest-services.nix @@ -15,6 +15,6 @@ in config = mkIf cfg.enable { services.qemuGuest.enable = true; services.spice-vdagentd.enable = true; - services.spice-webdavd.enable = true; - }; + services.spice-webdavd.enable = false; #Causes navfs2 build failure invalid neon version 9-12-25 + }; } From b5b6c95c89373fae585893e15945c268bf1c5c86 Mon Sep 17 00:00:00 2001 From: Don Williams Date: Tue, 16 Sep 2025 14:48:07 -0400 Subject: [PATCH 13/18] Remvoed upgrade script as it appears to have issues On branch stable-2.4 Your branch is up to date with 'origin/stable-2.4'. Changes to be committed: modified: README.md renamed: UPGRADE-2.3-to-2.4.es.md -> modules/src/UPGRADE-2.3-to-2.4.es.md renamed: UPGRADE-2.3-to-2.4.md -> modules/src/UPGRADE-2.3-to-2.4.md renamed: ZaneyOS-Upgrade.es.md -> modules/src/ZaneyOS-Upgrade.es.md renamed: ZaneyOS-Upgrade.md -> modules/src/ZaneyOS-Upgrade.md renamed: ZaneyOS-stable-2.4-announcement.es.md -> modules/src/ZaneyOS-stable-2.4-announcement.es.md renamed: ZaneyOS-stable-2.4-announcement.md -> modules/src/ZaneyOS-stable-2.4-announcement.md renamed: compare-zaneyos-config.sh -> modules/src/compare-zaneyos-config.sh renamed: revert-to-2.3.sh -> modules/src/revert-to-2.3.sh renamed: upgrade-2.3-to-2.4.sh -> modules/src/upgrade-2.3-to-2.4.sh --- README.md | 41 +++++++++++-------- .../src/UPGRADE-2.3-to-2.4.es.md | 0 .../src/UPGRADE-2.3-to-2.4.md | 0 .../src/ZaneyOS-Upgrade.es.md | 0 .../src/ZaneyOS-Upgrade.md | 0 .../src/ZaneyOS-stable-2.4-announcement.es.md | 0 .../src/ZaneyOS-stable-2.4-announcement.md | 0 .../src/compare-zaneyos-config.sh | 0 .../src/revert-to-2.3.sh | 0 .../src/upgrade-2.3-to-2.4.sh | 0 10 files changed, 25 insertions(+), 16 deletions(-) rename UPGRADE-2.3-to-2.4.es.md => modules/src/UPGRADE-2.3-to-2.4.es.md (100%) rename UPGRADE-2.3-to-2.4.md => modules/src/UPGRADE-2.3-to-2.4.md (100%) rename ZaneyOS-Upgrade.es.md => modules/src/ZaneyOS-Upgrade.es.md (100%) rename ZaneyOS-Upgrade.md => modules/src/ZaneyOS-Upgrade.md (100%) rename ZaneyOS-stable-2.4-announcement.es.md => modules/src/ZaneyOS-stable-2.4-announcement.es.md (100%) rename ZaneyOS-stable-2.4-announcement.md => modules/src/ZaneyOS-stable-2.4-announcement.md (100%) rename compare-zaneyos-config.sh => modules/src/compare-zaneyos-config.sh (100%) rename revert-to-2.3.sh => modules/src/revert-to-2.3.sh (100%) rename upgrade-2.3-to-2.4.sh => modules/src/upgrade-2.3-to-2.4.sh (100%) diff --git a/README.md b/README.md index f36bba6..e4f8423 100644 --- a/README.md +++ b/README.md @@ -24,8 +24,11 @@ This includes the wallpaper, scripts, applications, config files, and more. ### Cheatsheets and Guides -- Nix Beginner Guide: [English](cheatsheets/nix-beginner-guide.md) | [Español](cheatsheets/nix-beginner-guide.es.md) -- Hyprland Customization Guide: [English](cheatsheets/hyprland-customization-guide.md) | [Español](cheatsheets/hyprland-customization-guide.es.md) +- Nix Beginner Guide: [English](cheatsheets/nix-beginner-guide.md) | + [Español](cheatsheets/nix-beginner-guide.es.md) +- Hyprland Customization Guide: + [English](cheatsheets/hyprland-customization-guide.md) | + [Español](cheatsheets/hyprland-customization-guide.es.md) ### Please note: @@ -161,22 +164,25 @@ Below are the keybindings for Hyprland, formatted for easy reference. ## Installation: -> **⚠️ IMPORTANT:** These installation methods are for **NEW INSTALLATIONS ONLY**. -> If you already have ZaneyOS installed and want to upgrade to v2.4, see the [Upgrade Instructions](#upgrading-from-zaneyos-23-to-24) below. +> **⚠️ IMPORTANT:** These installation methods are for **NEW INSTALLATIONS +> ONLY**. If you already have ZaneyOS installed and want to upgrade to v2.4, see +> the [Upgrade Instructions](#upgrading-from-zaneyos-23-to-24) below. Note: Do +> NOT use upgrade script at this time. It will be restored later.
⬇️ Install with script (NEW INSTALLATIONS ONLY) ### 📜 Script: -This is the easiest and recommended way of starting out for **new installations**. The script is not meant -to allow you to change every option that you can in the flake or help you -install extra packages. It is simply here so you can get my configuration -installed with as little chances of breakages and then fiddle to your hearts -content! +This is the easiest and recommended way of starting out for **new +installations**. The script is not meant to allow you to change every option +that you can in the flake or help you install extra packages. It is simply here +so you can get my configuration installed with as little chances of breakages +and then fiddle to your hearts content! -> **⚠️ WARNING:** This script will completely replace any existing ~/zaneyos directory. -> Do NOT use this if you already have ZaneyOS installed and configured. +> **⚠️ WARNING:** This script will completely replace any existing ~/zaneyos +> directory. Do NOT use this if you already have ZaneyOS installed and +> configured. Simply copy this and run it: @@ -261,13 +267,15 @@ called `fr` that will rebuild the flake and you do not have to be in the
-## Upgrading from ZaneyOS 2.3 to 2.4 +## Upgrading from ZaneyOS 2.3 to 2.4 -- Do NOT use the upgrade script at this timel. -> **🚀 IMPORTANT:** If you already have ZaneyOS 2.3 installed, use the automated upgrade system instead of reinstalling! +> **🚀 IMPORTANT:** If you already have ZaneyOS 2.3 installed, use the automated +> upgrade system instead of reinstalling! ### ✅ Automated Upgrade Process: -ZaneyOS includes a comprehensive upgrade system that safely migrates your configuration: +ZaneyOS includes a comprehensive upgrade system that safely migrates your +configuration: ```bash cd ~/zaneyos @@ -285,7 +293,7 @@ cd ~/zaneyos ### 📋 What Gets Automatically Migrated: - ✅ All host configurations and variables -- ✅ Hardware configurations +- ✅ Hardware configurations - ✅ Custom packages (both global and per-host) - ✅ Themes, wallpapers, and monitor settings - ✅ Git configuration and personal settings @@ -302,7 +310,8 @@ cd ~/zaneyos For detailed upgrade instructions, troubleshooting, and safety information: - **Read**: `UPGRADE-2.3-to-2.4.md` in your zaneyos directory -- **Analysis Report**: Saved automatically as `~/zaneyos-upgrade-analysis-TIMESTAMP.txt` +- **Analysis Report**: Saved automatically as + `~/zaneyos-upgrade-analysis-TIMESTAMP.txt` ### 🔄 Easy Revert: diff --git a/UPGRADE-2.3-to-2.4.es.md b/modules/src/UPGRADE-2.3-to-2.4.es.md similarity index 100% rename from UPGRADE-2.3-to-2.4.es.md rename to modules/src/UPGRADE-2.3-to-2.4.es.md diff --git a/UPGRADE-2.3-to-2.4.md b/modules/src/UPGRADE-2.3-to-2.4.md similarity index 100% rename from UPGRADE-2.3-to-2.4.md rename to modules/src/UPGRADE-2.3-to-2.4.md diff --git a/ZaneyOS-Upgrade.es.md b/modules/src/ZaneyOS-Upgrade.es.md similarity index 100% rename from ZaneyOS-Upgrade.es.md rename to modules/src/ZaneyOS-Upgrade.es.md diff --git a/ZaneyOS-Upgrade.md b/modules/src/ZaneyOS-Upgrade.md similarity index 100% rename from ZaneyOS-Upgrade.md rename to modules/src/ZaneyOS-Upgrade.md diff --git a/ZaneyOS-stable-2.4-announcement.es.md b/modules/src/ZaneyOS-stable-2.4-announcement.es.md similarity index 100% rename from ZaneyOS-stable-2.4-announcement.es.md rename to modules/src/ZaneyOS-stable-2.4-announcement.es.md diff --git a/ZaneyOS-stable-2.4-announcement.md b/modules/src/ZaneyOS-stable-2.4-announcement.md similarity index 100% rename from ZaneyOS-stable-2.4-announcement.md rename to modules/src/ZaneyOS-stable-2.4-announcement.md diff --git a/compare-zaneyos-config.sh b/modules/src/compare-zaneyos-config.sh similarity index 100% rename from compare-zaneyos-config.sh rename to modules/src/compare-zaneyos-config.sh diff --git a/revert-to-2.3.sh b/modules/src/revert-to-2.3.sh similarity index 100% rename from revert-to-2.3.sh rename to modules/src/revert-to-2.3.sh diff --git a/upgrade-2.3-to-2.4.sh b/modules/src/upgrade-2.3-to-2.4.sh similarity index 100% rename from upgrade-2.3-to-2.4.sh rename to modules/src/upgrade-2.3-to-2.4.sh From e9c7fc52e1939504a0b693499687888c46fb0b53 Mon Sep 17 00:00:00 2001 From: Don Williams Date: Tue, 16 Sep 2025 15:05:19 -0400 Subject: [PATCH 14/18] Fix upgrade script: Add flake.nix update with user detection - Add update_flake_configuration() function to detect user's actual: * Username (from git config or whoami) * Hostname (from system or host directories) * GPU profile (from hardware detection: nvidia/amd/intel/vm) - Fix build process to use GPU profile instead of internal profile variable - Resolves issue where upgrade defaulted to 'dwilliams' user and 'vm' profile - Users now get their actual configuration preserved during upgrade Fixes: Three users reported upgrade didn't preserve their host info, username, and GPU profile --- modules/src/upgrade-2.3-to-2.4.sh | 83 +++++++++++++++++++++++++++++-- 1 file changed, 78 insertions(+), 5 deletions(-) diff --git a/modules/src/upgrade-2.3-to-2.4.sh b/modules/src/upgrade-2.3-to-2.4.sh index 256a17a..7446b5f 100755 --- a/modules/src/upgrade-2.3-to-2.4.sh +++ b/modules/src/upgrade-2.3-to-2.4.sh @@ -858,14 +858,87 @@ else print_warning "No backup found for modules/core/packages.nix - using defaults" fi +# Function to detect and update flake.nix with user's actual configuration +update_flake_configuration() { + print_header "Updating Flake Configuration" + + # Detect current username (prefer from old config, fallback to current user) + local detected_username + if [ -n "${HOST_DIRS[0]}" ] && [ -f "$BACKUP_DIR/zaneyos/hosts/${HOST_DIRS[0]}/variables.nix" ]; then + detected_username=$(grep 'gitUsername' "$BACKUP_DIR/zaneyos/hosts/${HOST_DIRS[0]}/variables.nix" | sed 's/.*= *"\([^"]*\)".*/\1/' | head -1) + fi + detected_username=${detected_username:-$(whoami)} + + # Detect current hostname (prefer from system, fallback to first host directory) + local detected_hostname=$(hostname) + if [[ "$detected_hostname" == "nixos" ]] || [[ -z "$detected_hostname" ]]; then + detected_hostname=${HOST_DIRS[0]} + fi + + # Detect GPU profile from hardware or ask user + local detected_profile="vm" # default fallback + print_info "Detecting GPU profile..." + + # Check for NVIDIA + if lspci | grep -i nvidia >/dev/null 2>&1; then + # Check if it's a laptop/mobile GPU + if lspci | grep -i nvidia | grep -i "mobile\|laptop" >/dev/null 2>&1; then + detected_profile="nvidia-laptop" + else + detected_profile="nvidia" + fi + # Check for AMD + elif lspci | grep -i amd | grep -i "VGA\|Display" >/dev/null 2>&1; then + detected_profile="amd" + # Check for Intel + elif lspci | grep -i intel | grep -i "VGA\|Display" >/dev/null 2>&1; then + detected_profile="intel" + # Check if we're in a VM environment + elif systemd-detect-virt >/dev/null 2>&1; then + detected_profile="vm" + print_info "Virtual machine environment detected" + fi + + print_info "Detected configuration:" + print_info " Username: $detected_username" + print_info " Hostname: $detected_hostname" + print_info " GPU Profile: $detected_profile" + + # Confirm with user before updating + echo "" + prompt_yes "Update flake.nix with detected configuration? (Y/N):" + if [[ ! $REPLY =~ ^[Yy]$ ]]; then + print_warning "Skipping flake.nix update - using current values" + return 0 + fi + + # Update flake.nix with detected values + print_info "Updating flake.nix..." + sed -i "s/username = \"[^\"]*\";/username = \"$detected_username\";/" ./flake.nix + sed -i "s/host = \"[^\"]*\";/host = \"$detected_hostname\";/" ./flake.nix + sed -i "s/profile = \"[^\"]*\";/profile = \"$detected_profile\";/" ./flake.nix + + print_success "✓ Updated flake.nix with detected configuration" + + # Show what was updated + print_info "Updated flake.nix contents:" + echo -e "${CYAN}$(grep -A 3 -E 'host =|username =|profile =' ./flake.nix)${NC}" + echo "" +} + +# Update flake.nix with user's actual configuration +update_flake_configuration + print_header "Building ZaneyOS 2.4" print_warning "Using 'boot' option to avoid SDDM display issues" print_info "This is safer than 'switch' when changing display managers" -# Get the profile from flake.nix -PROFILE=$(grep 'profile = ' ./flake.nix | sed 's/.*= *"\([^"]*\)".*/\1/') -print_info "Detected profile: $PROFILE" +# Get the GPU profile from flake.nix (this determines which nixosConfiguration to use) +# The actual build target is the GPU profile (amd, nvidia, nvidia-laptop, intel, vm) +# not the internal 'profile' variable which is just passed to modules +GPU_PROFILE=$(grep 'profile = ' ./flake.nix | sed 's/.*= *"\([^"]*\)".*/\1/') +print_info "Using GPU profile for build: $GPU_PROFILE" # Build the system echo "" @@ -882,12 +955,12 @@ BUILD_SUCCESS=false if [ "$USE_NH" = true ]; then print_info "Using NH for build..." - if nh os boot ~/zaneyos --hostname "$PROFILE"; then + if nh os boot ~/zaneyos --hostname "$GPU_PROFILE"; then BUILD_SUCCESS=true fi else print_info "Using nixos-rebuild for build..." - if sudo nixos-rebuild boot --flake ~/zaneyos/#"$PROFILE"; then + if sudo nixos-rebuild boot --flake ~/zaneyos/#"$GPU_PROFILE"; then BUILD_SUCCESS=true fi fi From 7927741e50df002308e6b449823c504b50571f23 Mon Sep 17 00:00:00 2001 From: Don Williams Date: Thu, 18 Sep 2025 17:25:22 -0400 Subject: [PATCH 15/18] Re-enabled symbola font On branch stable-2.4 Your branch is up to date with 'origin/stable-2.4'. Changes to be committed: modified: modules/core/fonts.nix --- modules/core/fonts.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/modules/core/fonts.nix b/modules/core/fonts.nix index 2703381..4861b8a 100644 --- a/modules/core/fonts.nix +++ b/modules/core/fonts.nix @@ -1,4 +1,5 @@ -{pkgs, ...}: { +{ pkgs, ... }: +{ fonts = { packages = with pkgs; [ dejavu_fonts @@ -22,7 +23,7 @@ powerline-fonts roboto roboto-mono - #symbola + symbola terminus_font ]; }; From 63830807e0131a90cd0a60899fdbb6d700d83d11 Mon Sep 17 00:00:00 2001 From: dwilliams Date: Thu, 18 Sep 2025 17:33:18 -0400 Subject: [PATCH 16/18] Updated flake w/symbola font enabled --- flake.lock | 42 ++++++++++++++--------------- hosts/zaneyos-24-vm/hardware.nix | 46 +++++++++++++++----------------- 2 files changed, 42 insertions(+), 46 deletions(-) diff --git a/flake.lock b/flake.lock index 99b5ea2..0ce33cb 100644 --- a/flake.lock +++ b/flake.lock @@ -107,11 +107,11 @@ ] }, "locked": { - "lastModified": 1754487366, - "narHash": "sha256-pHYj8gUBapuUzKV/kN/tR3Zvqc7o6gdFB9XKXIp1SQ8=", + "lastModified": 1756770412, + "narHash": "sha256-+uWLQZccFHwqpGqr2Yt5VsW/PbeJVTn9Dk6SHWhNRPw=", "owner": "hercules-ci", "repo": "flake-parts", - "rev": "af66ad14b28a127c5c0f3bbb298218fc63528a18", + "rev": "4524271976b625a4a605beefd893f270620fd751", "type": "github" }, "original": { @@ -181,11 +181,11 @@ ] }, "locked": { - "lastModified": 1756245065, - "narHash": "sha256-aAZNbGcWrVRZgWgkQbkabSGcDVRDMgON4BipMy69gvI=", + "lastModified": 1757808926, + "narHash": "sha256-K6PEI5PYY94TVMH0mX3MbZNYFme7oNRKml/85BpRRAo=", "owner": "nix-community", "repo": "home-manager", - "rev": "54b2879ce622d44415e727905925e21b8f833a98", + "rev": "f21d9167782c086a33ad53e2311854a8f13c281e", "type": "github" }, "original": { @@ -197,11 +197,11 @@ }, "mnw": { "locked": { - "lastModified": 1748710831, - "narHash": "sha256-eZu2yH3Y2eA9DD3naKWy/sTxYS5rPK2hO7vj8tvUCSU=", + "lastModified": 1756659871, + "narHash": "sha256-v6Rh4aQ6RKjM2N02kK9Usn0Ix7+OY66vNpeklc1MnGE=", "owner": "Gerg-L", "repo": "mnw", - "rev": "cff958a4e050f8d917a6ff3a5624bc4681c6187d", + "rev": "ed6cc3e48557ba18266e598a5ebb6602499ada16", "type": "github" }, "original": { @@ -228,11 +228,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1754937576, - "narHash": "sha256-3sWA5WJybUE16kIMZ3+uxcxKZY/JRR4DFBqLdSLBo7w=", + "lastModified": 1758070117, + "narHash": "sha256-uLwwHFCZnT1c3N3biVe/0hCkag2GSrf9+M56+Okf+WY=", "owner": "nixos", "repo": "nixpkgs", - "rev": "84c26d62ce9e15489c63b83fc44e6eb62705d2c9", + "rev": "e9b7f2ff62b35f711568b1f0866243c7c302028d", "type": "github" }, "original": { @@ -244,11 +244,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1755049066, - "narHash": "sha256-ANrc15FSoOAdNbfKHxqEJjZLftIwIsenJGRb/04K41s=", + "lastModified": 1756696532, + "narHash": "sha256-6FWagzm0b7I/IGigOv9pr6LL7NQ86mextfE8g8Q6HBg=", "owner": "nixos", "repo": "nixpkgs", - "rev": "e45f8f193029378d0aaee5431ba098dc80054e9a", + "rev": "58dcbf1ec551914c3756c267b8b9c8c86baa1b2f", "type": "github" }, "original": { @@ -309,11 +309,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1755463179, - "narHash": "sha256-5Ggb1Mhf7ZlRgGi2puCa2PvWs6KbMnWBlW6KW7Vf79Y=", + "lastModified": 1757955071, + "narHash": "sha256-owSpkt551cIqDDk5iHesdEus9REFeOIY3rY4C5ZPm/Y=", "owner": "notashelf", "repo": "nvf", - "rev": "03833118267ad32226b014b360692bdce9d6e082", + "rev": "1bd9fc116420db4c1156819d61df5d5312e1bbea", "type": "github" }, "original": { @@ -350,11 +350,11 @@ "tinted-zed": "tinted-zed" }, "locked": { - "lastModified": 1755710103, - "narHash": "sha256-VmheUy4UzWDy/u0TvCCHptgF30peL7wRxkHy7EVpDrQ=", + "lastModified": 1757957798, + "narHash": "sha256-FT4O5imFJ+FUIGhYj/aFwEEgyvLhuyJ2my8f6mCLtTY=", "owner": "danth", "repo": "stylix", - "rev": "79be65b20d7b8fb7e8f39ba8121cfe41b7f46808", + "rev": "e6fc25cd12e8f461e402cf34649cc73ad93c7bdd", "type": "github" }, "original": { diff --git a/hosts/zaneyos-24-vm/hardware.nix b/hosts/zaneyos-24-vm/hardware.nix index e8914eb..0289b85 100644 --- a/hosts/zaneyos-24-vm/hardware.nix +++ b/hosts/zaneyos-24-vm/hardware.nix @@ -1,6 +1,3 @@ -# Do not modify this file! It was generated by ‘nixos-generate-config’ -# and may be overwritten by future invocations. Please make changes -# to /etc/nixos/configuration.nix instead. { config, lib, pkgs, modulesPath, ... }: { @@ -8,38 +5,37 @@ [ (modulesPath + "/profiles/qemu-guest.nix") ]; - boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ]; - boot.initrd.kernelModules = [ ]; - boot.kernelModules = [ "kvm-intel" ]; - boot.extraModulePackages = [ ]; + boot = { + initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod" ]; + initrd.kernelModules = [ ]; + kernelModules = [ "kvm-intel" ]; + extraModulePackages = [ ]; + }; - fileSystems."/" = - { device = "/dev/disk/by-uuid/e5fc1006-4d0b-41db-8c43-22b3cb8110c6"; - fsType = "ext4"; + fileSystems = { + "/" + = { + device = "/dev/disk/by-uuid/e5fc1006-4d0b-41db-8c43-22b3cb8110c6"; + fsType = "ext4"; }; - - fileSystems."/boot" = - { device = "/dev/disk/by-uuid/9287-3738"; - fsType = "vfat"; - options = [ "fmask=0077" "dmask=0077" ]; + "/boot" = { + device = "/dev/disk/by-uuid/9287-3738"; + fsType = "vfat"; + options = [ "fmask=0077" "dmask=0077" ]; }; - - fileSystems."/mnt/nas" = - { device = "192.168.40.11:/volume1/DiskStation54TB"; + "/mnt/nas" = { + device = "192.168.40.11:/volume1/DiskStation54TB"; fsType = "nfs"; + options = [ "rw" "bg" "tcp" "soft" "_netdev" ]; }; + }; swapDevices = [ { device = "/dev/disk/by-uuid/a6e9dd8b-6767-44f4-84fa-30d02d90d087"; } ]; - # Enables DHCP on each ethernet and wireless interface. In case of scripted networking - # (the default) this is the recommended approach. When using systemd-networkd it's - # still possible to use this option, but it's recommended to use it in conjunction - # with explicit per-interface declarations with `networking.interfaces..useDHCP`. networking.useDHCP = lib.mkDefault true; - # networking.interfaces.docker0.useDHCP = lib.mkDefault true; - # networking.interfaces.ens18.useDHCP = lib.mkDefault true; - nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + + security.sudo.wheelNeedsPassword = false; } From 579db591a091eb28bc317ec5d165f7121d87f2a4 Mon Sep 17 00:00:00 2001 From: dwilliams Date: Mon, 29 Sep 2025 21:16:13 -0400 Subject: [PATCH 17/18] Updated flake --- flake.lock | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/flake.lock b/flake.lock index 0ce33cb..f61677e 100644 --- a/flake.lock +++ b/flake.lock @@ -181,11 +181,11 @@ ] }, "locked": { - "lastModified": 1757808926, - "narHash": "sha256-K6PEI5PYY94TVMH0mX3MbZNYFme7oNRKml/85BpRRAo=", + "lastModified": 1758463745, + "narHash": "sha256-uhzsV0Q0I9j2y/rfweWeGif5AWe0MGrgZ/3TjpDYdGA=", "owner": "nix-community", "repo": "home-manager", - "rev": "f21d9167782c086a33ad53e2311854a8f13c281e", + "rev": "3b955f5f0a942f9f60cdc9cacb7844335d0f21c3", "type": "github" }, "original": { @@ -228,11 +228,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1758070117, - "narHash": "sha256-uLwwHFCZnT1c3N3biVe/0hCkag2GSrf9+M56+Okf+WY=", + "lastModified": 1758791193, + "narHash": "sha256-F8WmEwFoHsnix7rt290R0rFXNJiMbClMZyIC/e+HYf0=", "owner": "nixos", "repo": "nixpkgs", - "rev": "e9b7f2ff62b35f711568b1f0866243c7c302028d", + "rev": "25e53aa156d47bad5082ff7618f5feb1f5e02d01", "type": "github" }, "original": { @@ -309,11 +309,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1757955071, - "narHash": "sha256-owSpkt551cIqDDk5iHesdEus9REFeOIY3rY4C5ZPm/Y=", + "lastModified": 1758271661, + "narHash": "sha256-ENqd2/33uP5vB44ClDjjAV+J78oF8q1er4QUZuT8Z7g=", "owner": "notashelf", "repo": "nvf", - "rev": "1bd9fc116420db4c1156819d61df5d5312e1bbea", + "rev": "b7571df4d6e9ac08506a738ddceeec0b141751b0", "type": "github" }, "original": { @@ -350,11 +350,11 @@ "tinted-zed": "tinted-zed" }, "locked": { - "lastModified": 1757957798, - "narHash": "sha256-FT4O5imFJ+FUIGhYj/aFwEEgyvLhuyJ2my8f6mCLtTY=", + "lastModified": 1759050585, + "narHash": "sha256-Mj99rGy+K9jaQ85U2YWydZ9OKCIAdkxClrJlfG04GxU=", "owner": "danth", "repo": "stylix", - "rev": "e6fc25cd12e8f461e402cf34649cc73ad93c7bdd", + "rev": "3f71498ed14405aea347b9f5b7f56d97e64e904c", "type": "github" }, "original": { From a43d432647656dd5e145505df18dfcd207043b33 Mon Sep 17 00:00:00 2001 From: dwilliams Date: Sat, 4 Oct 2025 15:51:31 -0400 Subject: [PATCH 18/18] Changed emacs-gtk to emac-pgtk for wayland support On branch stable-2.4 Your branch is up to date with 'origin/stable-2.4'. Changes to be committed: modified: hosts/zaneyos-24-vm/variables.nix modified: modules/home/editors/doom-emacs.nix --- hosts/zaneyos-24-vm/variables.nix | 2 +- modules/home/editors/doom-emacs.nix | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hosts/zaneyos-24-vm/variables.nix b/hosts/zaneyos-24-vm/variables.nix index d177f37..4036d73 100644 --- a/hosts/zaneyos-24-vm/variables.nix +++ b/hosts/zaneyos-24-vm/variables.nix @@ -18,7 +18,7 @@ # Note: This is evil-helix with VIM keybindings by default helixEnable = false; #To install: Enable here, zcli rebuild, then run zcli doom install - doomEmacsEnable = false; + doomEmacsEnable = true; # Hyprland Settings # Examples: diff --git a/modules/home/editors/doom-emacs.nix b/modules/home/editors/doom-emacs.nix index e9cd845..ca1f248 100644 --- a/modules/home/editors/doom-emacs.nix +++ b/modules/home/editors/doom-emacs.nix @@ -1,7 +1,7 @@ { pkgs, ... }: { home.packages = with pkgs; [ - emacs-gtk + emacs-pgtk git lazygit ripgrep