# cschneegans/unattend-generator architecture

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

- Interactive diagram: https://gitdiagram.com/cschneegans/unattend-generator
- Repository: https://github.com/cschneegans/unattend-generator

## Overview

UnattendGenerator is a .NET library that turns Windows installation settings into an autounattend.xml document, forming the basis of an online generator. The principal workflow is configuration input, application of setup-pass and customization modifiers, then XML output. Its distinct domain stages include disk setup, accounts, networking, software removal, and system personalization; scripts are an internal layer that places commands into setup phases. Main.cs shows modifier registration and references several core modules. Other modifier relationships are limited to those supported by the source index; unsampled implementation details are not inferred.

Main entry points: [`Main.cs`](https://github.com/cschneegans/unattend-generator/blob/master/Main.cs) (Generator orchestration), [`modifier/Script.cs`](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Script.cs) (Custom scripts), [`modifier/Disk.cs`](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Disk.cs) (Disk setup), [`modifier/Bloatware.cs`](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Bloatware.cs) (App removal)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_generation["Generation"]
  node_main["Generator orchestration<br/>[Main.cs]"]
  node_output["Unattend XML"]
  node_validation["Input validation<br/>[Validation.cs]"]
  node_resources["Resource utilities<br/>[Util.cs]"]
end

subgraph group_setup["Setup configuration"]
  node_disk["Disk setup<br/>[Disk.cs]"]
  node_computer["Computer name<br/>[ComputerName.cs]"]
  node_accounts["User accounts<br/>[Users.cs]"]
  node_defaultuser["Default user<br/>[DefaultUser.cs]"]
  node_wifi["Wi-Fi setup<br/>[Wifi.cs]"]
  node_timezone["Time zone<br/>[TimeZone.cs]"]
  node_locales["Language settings<br/>[Locales.cs]"]
  node_productkey["Product key<br/>[ProductKey.cs]"]
end

subgraph group_customization["Windows customization"]
  node_bloatware["App removal<br/>[Bloatware.cs]"]
  node_optimizations["System preferences<br/>[Optimizations.cs]"]
  node_components["Setup components<br/>[Components.cs]"]
  node_applocker["AppLocker policy<br/>[AppLocker.cs]"]
  node_personalization["Personalization<br/>[Personalization.cs]"]
end

subgraph group_execution["Script execution"]
  node_scripts["Custom scripts<br/>[Script.cs]"]
  node_specialize["Specialize phase<br/>[Specialize.cs]"]
  node_firstlogon["First logon phase<br/>[FirstLogon.cs]"]
  node_useronce["User once phase<br/>[UserOnce.cs]"]
end

node_user(("Library caller"))

node_user -->|"configures"| node_main
node_main -->|"registers"| node_disk
node_main -->|"registers"| node_accounts
node_main -->|"registers"| node_defaultuser
node_main -->|"registers"| node_components
node_main -->|"registers"| node_specialize
node_main -->|"registers"| node_useronce
node_main -->|"references"| node_bloatware
node_main -->|"references"| node_timezone
node_main -->|"references"| node_productkey
node_main -->|"references"| node_firstlogon
node_main -->|"references"| node_optimizations
node_main -->|"generates"| node_output
node_disk -->|"uses"| node_scripts
node_computer -->|"uses"| node_scripts
node_bloatware -->|"invokes"| node_scripts
node_optimizations -->|"loads resources"| node_resources
node_wifi -->|"loads profile"| node_resources
node_scripts -->|"routes system scripts"| node_specialize
node_scripts -->|"routes scripts"| node_firstlogon
node_scripts -->|"routes scripts"| node_useronce

click node_main "https://github.com/cschneegans/unattend-generator/blob/master/Main.cs"
click node_validation "https://github.com/cschneegans/unattend-generator/blob/master/Validation.cs"
click node_disk "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Disk.cs"
click node_computer "https://github.com/cschneegans/unattend-generator/blob/master/modifier/ComputerName.cs"
click node_accounts "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Users.cs"
click node_defaultuser "https://github.com/cschneegans/unattend-generator/blob/master/modifier/DefaultUser.cs"
click node_wifi "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Wifi.cs"
click node_timezone "https://github.com/cschneegans/unattend-generator/blob/master/modifier/TimeZone.cs"
click node_locales "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Locales.cs"
click node_productkey "https://github.com/cschneegans/unattend-generator/blob/master/modifier/ProductKey.cs"
click node_bloatware "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Bloatware.cs"
click node_optimizations "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Optimizations.cs"
click node_components "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Components.cs"
click node_applocker "https://github.com/cschneegans/unattend-generator/blob/master/modifier/AppLocker.cs"
click node_personalization "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Personalization.cs"
click node_scripts "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Script.cs"
click node_specialize "https://github.com/cschneegans/unattend-generator/blob/master/modifier/Specialize.cs"
click node_firstlogon "https://github.com/cschneegans/unattend-generator/blob/master/modifier/FirstLogon.cs"
click node_useronce "https://github.com/cschneegans/unattend-generator/blob/master/modifier/UserOnce.cs"
click node_resources "https://github.com/cschneegans/unattend-generator/blob/master/Util.cs"

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_main,node_output,node_validation,node_resources toneBlue
class node_disk,node_computer,node_accounts,node_defaultuser,node_wifi,node_timezone,node_locales,node_productkey toneAmber
class node_bloatware,node_optimizations,node_components,node_applocker,node_personalization toneMint
class node_scripts,node_specialize,node_firstlogon,node_useronce toneRose
class node_user toneIndigo
```

## Components

### Generation

- [Generator orchestration](https://github.com/cschneegans/unattend-generator/blob/master/Main.cs): `Main.cs`
- **Unattend XML**
- [Input validation](https://github.com/cschneegans/unattend-generator/blob/master/Validation.cs): `Validation.cs`
- [Resource utilities](https://github.com/cschneegans/unattend-generator/blob/master/Util.cs): `Util.cs`

### Setup configuration

- [Disk setup](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Disk.cs): `modifier/Disk.cs`
- [Computer name](https://github.com/cschneegans/unattend-generator/blob/master/modifier/ComputerName.cs): `modifier/ComputerName.cs`
- [User accounts](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Users.cs): `modifier/Users.cs`
- [Default user](https://github.com/cschneegans/unattend-generator/blob/master/modifier/DefaultUser.cs): `modifier/DefaultUser.cs`
- [Wi-Fi setup](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Wifi.cs): `modifier/Wifi.cs`
- [Time zone](https://github.com/cschneegans/unattend-generator/blob/master/modifier/TimeZone.cs): `modifier/TimeZone.cs`
- [Language settings](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Locales.cs): `modifier/Locales.cs`
- [Product key](https://github.com/cschneegans/unattend-generator/blob/master/modifier/ProductKey.cs): `modifier/ProductKey.cs`

### Windows customization

- [App removal](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Bloatware.cs): `modifier/Bloatware.cs`
- [System preferences](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Optimizations.cs): `modifier/Optimizations.cs`
- [Setup components](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Components.cs): `modifier/Components.cs`
- [AppLocker policy](https://github.com/cschneegans/unattend-generator/blob/master/modifier/AppLocker.cs): `modifier/AppLocker.cs`
- [Personalization](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Personalization.cs): `modifier/Personalization.cs`

### Script execution

- [Custom scripts](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Script.cs): `modifier/Script.cs`
- [Specialize phase](https://github.com/cschneegans/unattend-generator/blob/master/modifier/Specialize.cs): `modifier/Specialize.cs`
- [First logon phase](https://github.com/cschneegans/unattend-generator/blob/master/modifier/FirstLogon.cs): `modifier/FirstLogon.cs`
- [User once phase](https://github.com/cschneegans/unattend-generator/blob/master/modifier/UserOnce.cs): `modifier/UserOnce.cs`

### Other components

- **Library caller**

## Connections

- Library caller → Generator orchestration: configures (evidence: `README.md`)
- Generator orchestration → Disk setup: registers (evidence: `Main.cs`)
- Generator orchestration → User accounts: registers (evidence: `Main.cs`)
- Generator orchestration → Default user: registers (evidence: `Main.cs`)
- Generator orchestration → Setup components: registers (evidence: `Main.cs`)
- Generator orchestration → Specialize phase: registers (evidence: `Main.cs`)
- Generator orchestration → User once phase: registers (evidence: `Main.cs`)
- Generator orchestration → App removal: references (evidence: `Main.cs`)
- Generator orchestration → Time zone: references (evidence: `Main.cs`)
- Generator orchestration → Product key: references (evidence: `Main.cs`)
- Generator orchestration → First logon phase: references (evidence: `Main.cs`)
- Generator orchestration → System preferences: references (evidence: `Main.cs`)
- Generator orchestration → Unattend XML: generates (evidence: `README.md`)
- Disk setup → Custom scripts: uses (evidence: `modifier/Disk.cs`)
- Computer name → Custom scripts: uses (evidence: `modifier/ComputerName.cs`)
- App removal → Custom scripts: invokes (evidence: `modifier/Bloatware.cs`)
- System preferences → Resource utilities: loads resources (evidence: `modifier/Optimizations.cs`)
- Wi-Fi setup → Resource utilities: loads profile (evidence: `modifier/Wifi.cs`)
- Custom scripts → Specialize phase: routes system scripts (evidence: `modifier/Script.cs`)
- Custom scripts → First logon phase: routes scripts (evidence: `modifier/Script.cs`)
- Custom scripts → User once phase: routes scripts (evidence: `modifier/Script.cs`)
