# mkiin/dotfiles architecture

> Architecture diagram of the GitHub repository mkiin/dotfiles, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-25). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/mkiin/dotfiles
- Repository: https://github.com/mkiin/dotfiles

## Overview

This repository configures a personal NixOS desktop and its Home Manager user environment. The documented workflow selects a host, then uses the flake’s build or switch app to evaluate that host configuration; switching applies the system and integrated home configuration. The graph preserves the main system, desktop, user-environment, and secrets concerns visible in the README and tree. The sampled source only covers a browser extension, so internal wiring beyond the README’s documented relationships is intentionally limited.

Main entry points: [`hosts/oregairu-yukino/default.nix`](https://github.com/mkiin/dotfiles/blob/main/hosts/oregairu-yukino/default.nix) (Yukino host), [`home/linux/desktop/default.nix`](https://github.com/mkiin/dotfiles/blob/main/home/linux/desktop/default.nix) (Linux home), [`flake/apps/default.nix`](https://github.com/mkiin/dotfiles/blob/main/flake/apps/default.nix) (Build / switch), [`home/base/home.nix`](https://github.com/mkiin/dotfiles/blob/main/home/base/home.nix) (Home entry)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Flake entrypoints"]
  node_build_switch["Build / switch<br/>[default.nix]"]
  node_flake_hosts["Host outputs<br/>[default.nix]"]
end

subgraph group_system["NixOS system"]
  node_yukino["Yukino host<br/>[default.nix]"]
  node_hardware["Hardware config"]
  node_nixos_base["Base system<br/>[default.nix]"]
  node_nixos_desktop["Desktop system<br/>[default.nix]"]
  node_secrets["Secrets config<br/>[default.nix]"]
end

subgraph group_home["Home environment"]
  node_home_entry["Home entry<br/>[home.nix]"]
  node_home_base["Shared home<br/>[default.nix]"]
  node_home_linux["Linux home<br/>[default.nix]"]
  node_terminal["Terminal tools<br/>[default.nix]"]
  node_neovim["Neovim setup<br/>[default.nix]"]
end

subgraph group_desktop["Desktop experience"]
  node_hyprland["Hyprland<br/>[default.nix]"]
  node_quick_shell["Quickshell UI<br/>[default.nix]"]
  node_desktop_apps["Desktop apps<br/>[default.nix]"]
end

node_operator(("Operator"))
node_installed["Configured system"]

node_operator -->|"selects action"| node_build_switch
node_build_switch -->|"targets host"| node_flake_hosts
node_flake_hosts -->|"selects config"| node_yukino
node_yukino -->|"uses hardware"| node_hardware
node_yukino -->|"includes modules"| node_nixos_base
node_yukino -->|"includes modules"| node_nixos_desktop
node_yukino -->|"integrates home"| node_home_entry
node_home_entry -->|"configures"| node_home_base
node_home_entry -->|"configures"| node_home_linux
node_home_base -->|"configures"| node_terminal
node_terminal -->|"configures"| node_neovim
node_home_linux -->|"configures"| node_hyprland
node_home_linux -->|"configures"| node_quick_shell
node_home_linux -->|"configures"| node_desktop_apps
node_yukino -.->|"uses secrets"| node_secrets
node_build_switch -->|"switch applies"| node_installed

click node_build_switch "https://github.com/mkiin/dotfiles/blob/main/flake/apps/default.nix"
click node_flake_hosts "https://github.com/mkiin/dotfiles/blob/main/flake/hosts/default.nix"
click node_yukino "https://github.com/mkiin/dotfiles/blob/main/hosts/oregairu-yukino/default.nix"
click node_hardware "https://github.com/mkiin/dotfiles/blob/main/hosts/oregairu-yukino/hardware-configuration.nix"
click node_nixos_base "https://github.com/mkiin/dotfiles/blob/main/modules/nixos/base/default.nix"
click node_nixos_desktop "https://github.com/mkiin/dotfiles/blob/main/modules/nixos/desktop/default.nix"
click node_home_entry "https://github.com/mkiin/dotfiles/blob/main/home/base/home.nix"
click node_home_base "https://github.com/mkiin/dotfiles/blob/main/home/base/default.nix"
click node_home_linux "https://github.com/mkiin/dotfiles/blob/main/home/linux/desktop/default.nix"
click node_terminal "https://github.com/mkiin/dotfiles/blob/main/home/base/terminal/default.nix"
click node_neovim "https://github.com/mkiin/dotfiles/blob/main/home/base/terminal/neovim/default.nix"
click node_hyprland "https://github.com/mkiin/dotfiles/blob/main/home/linux/desktop/hyprland/default.nix"
click node_quick_shell "https://github.com/mkiin/dotfiles/blob/main/home/linux/desktop/ui/quickshell/default.nix"
click node_desktop_apps "https://github.com/mkiin/dotfiles/blob/main/home/linux/desktop/desktop-apps/default.nix"
click node_secrets "https://github.com/mkiin/dotfiles/blob/main/secrets/default.nix"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_build_switch,node_flake_hosts toneBlue
class node_yukino,node_hardware,node_nixos_base,node_nixos_desktop,node_secrets toneAmber
class node_home_entry,node_home_base,node_home_linux,node_terminal,node_neovim toneMint
class node_hyprland,node_quick_shell,node_desktop_apps toneRose
class node_operator,node_installed toneIndigo
```

## Components

### Flake entrypoints

- [Build / switch](https://github.com/mkiin/dotfiles/blob/main/flake/apps/default.nix): `flake/apps/default.nix`
- [Host outputs](https://github.com/mkiin/dotfiles/blob/main/flake/hosts/default.nix): `flake/hosts/default.nix`

### NixOS system

- [Yukino host](https://github.com/mkiin/dotfiles/blob/main/hosts/oregairu-yukino/default.nix): `hosts/oregairu-yukino/default.nix`
- [Hardware config](https://github.com/mkiin/dotfiles/blob/main/hosts/oregairu-yukino/hardware-configuration.nix): `hosts/oregairu-yukino/hardware-configuration.nix`
- [Base system](https://github.com/mkiin/dotfiles/blob/main/modules/nixos/base/default.nix): `modules/nixos/base/default.nix`
- [Desktop system](https://github.com/mkiin/dotfiles/blob/main/modules/nixos/desktop/default.nix): `modules/nixos/desktop/default.nix`
- [Secrets config](https://github.com/mkiin/dotfiles/blob/main/secrets/default.nix): `secrets/default.nix`

### Home environment

- [Home entry](https://github.com/mkiin/dotfiles/blob/main/home/base/home.nix): `home/base/home.nix`
- [Shared home](https://github.com/mkiin/dotfiles/blob/main/home/base/default.nix): `home/base/default.nix`
- [Linux home](https://github.com/mkiin/dotfiles/blob/main/home/linux/desktop/default.nix): `home/linux/desktop/default.nix`
- [Terminal tools](https://github.com/mkiin/dotfiles/blob/main/home/base/terminal/default.nix): `home/base/terminal/default.nix`
- [Neovim setup](https://github.com/mkiin/dotfiles/blob/main/home/base/terminal/neovim/default.nix): `home/base/terminal/neovim/default.nix`

### Desktop experience

- [Hyprland](https://github.com/mkiin/dotfiles/blob/main/home/linux/desktop/hyprland/default.nix): `home/linux/desktop/hyprland/default.nix`
- [Quickshell UI](https://github.com/mkiin/dotfiles/blob/main/home/linux/desktop/ui/quickshell/default.nix): `home/linux/desktop/ui/quickshell/default.nix`
- [Desktop apps](https://github.com/mkiin/dotfiles/blob/main/home/linux/desktop/desktop-apps/default.nix): `home/linux/desktop/desktop-apps/default.nix`

### Other components

- **Operator**
- **Configured system**

## Connections

- Operator → Build / switch: selects action
- Build / switch → Host outputs: targets host
- Host outputs → Yukino host: selects config
- Yukino host → Hardware config: uses hardware
- Yukino host → Base system: includes modules
- Yukino host → Desktop system: includes modules
- Yukino host → Home entry: integrates home
- Home entry → Shared home: configures
- Home entry → Linux home: configures
- Shared home → Terminal tools: configures
- Terminal tools → Neovim setup: configures
- Linux home → Hyprland: configures
- Linux home → Quickshell UI: configures
- Linux home → Desktop apps: configures
- Yukino host → Secrets config: uses secrets
- Build / switch → Configured system: switch applies
