# notchapplez/unin architecture

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

- Interactive diagram: https://gitdiagram.com/notchapplez/unin
- Repository: https://github.com/notchapplez/unin

## Overview

unin is a Linux-oriented universal project builder and installer. The main workflow is a user CLI request, project/build-file detection, dispatch to a language or build-system backend, and—unless `--noinstall` is used—installation and package registration. Separate CLI branches set up toolchains, clean build artifacts, fetch Git URLs, and inspect or uninstall registered packages. The README documents broader language support than the sampled backend excerpts; those backends are included by their exact paths, but uncertain internal steps are not expanded.

Main entry points: [`src/tools.rs`](https://github.com/notchapplez/unin/blob/main/src/tools.rs) (Detect and route), [`src/main.rs`](https://github.com/notchapplez/unin/blob/main/src/main.rs) (Command entry), [`src/registry.rs`](https://github.com/notchapplez/unin/blob/main/src/registry.rs) (Package registry), [`src/cmake.rs`](https://github.com/notchapplez/unin/blob/main/src/cmake.rs) (CMake builder)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_control["CLI and dispatch"]
  node_main["Command entry<br/>[main.rs]"]
  node_tools["Detect and route<br/>[tools.rs]"]
  node_git["Git fetch<br/>[git.rs]"]
end

subgraph group_builders["Build backends"]
  node_cmake["CMake builder<br/>[cmake.rs]"]
  node_make["Make builder<br/>[make.rs]"]
  node_configure["Configure builder<br/>[confidcure.rs]"]
  node_meson["Meson builder<br/>[meson.rs]"]
  node_rust["Rust builder<br/>[rust.rs]"]
  node_go["Go builder<br/>[go.rs]"]
  node_zig["Zig builder<br/>[zig.rs]"]
  node_gleam["Gleam builder<br/>[gleam.rs]"]
  node_haskell["Haskell builder<br/>[haskell.rs]"]
end

subgraph group_system["System and registry"]
  node_installer["Toolchain setup<br/>[installer.rs]"]
  node_tools_install["Binary installation<br/>[tools.rs]"]
  node_registry[("Package registry<br/>[registry.rs]")]
  node_logging["Build logs<br/>[logging.rs]"]
end

node_user(("CLI user"))
node_os["Linux system"]
node_package_managers["Package managers"]

node_user -->|"invokes"| node_main
node_main -->|"checks registry"| node_registry
node_main -->|"detects project"| node_tools
node_main -->|"fetches URL"| node_git
node_main -->|"sets up tools"| node_installer
node_main -->|"dispatches clean"| node_tools
node_main -->|"lists or uninstalls"| node_registry
node_tools -->|"dispatches"| node_cmake
node_tools -->|"dispatches"| node_make
node_tools -->|"dispatches"| node_configure
node_tools -->|"dispatches"| node_meson
node_tools -->|"dispatches"| node_rust
node_tools -->|"dispatches"| node_go
node_tools -->|"dispatches"| node_zig
node_tools -->|"dispatches"| node_gleam
node_tools -->|"dispatches"| node_haskell
node_tools -->|"cleans"| node_cmake
node_tools -->|"cleans"| node_make
node_tools -->|"cleans"| node_configure
node_tools -->|"cleans"| node_meson
node_tools -->|"cleans"| node_rust
node_tools -->|"cleans"| node_go
node_tools -->|"cleans"| node_zig
node_tools -->|"cleans"| node_gleam
node_tools -->|"cleans"| node_haskell
node_rust -->|"installs binaries"| node_tools_install
node_cmake -->|"registers binaries"| node_registry
node_configure -->|"registers binaries"| node_registry
node_meson -->|"registers binaries"| node_registry
node_gleam -->|"registers package"| node_registry
node_make -->|"registers installs"| node_registry
node_tools_install -->|"copies to bin"| node_os
node_registry -->|"reads and writes files"| node_os
node_registry -->|"deletes package files"| node_os
node_main -.->|"logs"| node_logging
node_installer -->|"installs packages"| node_package_managers

click node_main "https://github.com/notchapplez/unin/blob/main/src/main.rs"
click node_tools "https://github.com/notchapplez/unin/blob/main/src/tools.rs"
click node_git "https://github.com/notchapplez/unin/blob/main/src/git.rs"
click node_installer "https://github.com/notchapplez/unin/blob/main/src/installer.rs"
click node_cmake "https://github.com/notchapplez/unin/blob/main/src/cmake.rs"
click node_make "https://github.com/notchapplez/unin/blob/main/src/make.rs"
click node_configure "https://github.com/notchapplez/unin/blob/main/src/confidcure.rs"
click node_meson "https://github.com/notchapplez/unin/blob/main/src/meson.rs"
click node_rust "https://github.com/notchapplez/unin/blob/main/src/rust.rs"
click node_go "https://github.com/notchapplez/unin/blob/main/src/go.rs"
click node_zig "https://github.com/notchapplez/unin/blob/main/src/zig.rs"
click node_gleam "https://github.com/notchapplez/unin/blob/main/src/gleam.rs"
click node_haskell "https://github.com/notchapplez/unin/blob/main/src/haskell.rs"
click node_tools_install "https://github.com/notchapplez/unin/blob/main/src/tools.rs"
click node_registry "https://github.com/notchapplez/unin/blob/main/src/registry.rs"
click node_logging "https://github.com/notchapplez/unin/blob/main/src/logging.rs"

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_tools,node_git,node_user toneBlue
class node_cmake,node_make,node_configure,node_meson,node_rust,node_go,node_zig,node_gleam,node_haskell toneAmber
class node_installer,node_tools_install,node_registry,node_logging toneMint
class node_os,node_package_managers toneIndigo
```

## Components

### CLI and dispatch

- [Command entry](https://github.com/notchapplez/unin/blob/main/src/main.rs): `src/main.rs`
- [Detect and route](https://github.com/notchapplez/unin/blob/main/src/tools.rs): `src/tools.rs`
- [Git fetch](https://github.com/notchapplez/unin/blob/main/src/git.rs): `src/git.rs`

### Build backends

- [CMake builder](https://github.com/notchapplez/unin/blob/main/src/cmake.rs): `src/cmake.rs`
- [Make builder](https://github.com/notchapplez/unin/blob/main/src/make.rs): `src/make.rs`
- [Configure builder](https://github.com/notchapplez/unin/blob/main/src/confidcure.rs): `src/confidcure.rs`
- [Meson builder](https://github.com/notchapplez/unin/blob/main/src/meson.rs): `src/meson.rs`
- [Rust builder](https://github.com/notchapplez/unin/blob/main/src/rust.rs): `src/rust.rs`
- [Go builder](https://github.com/notchapplez/unin/blob/main/src/go.rs): `src/go.rs`
- [Zig builder](https://github.com/notchapplez/unin/blob/main/src/zig.rs): `src/zig.rs`
- [Gleam builder](https://github.com/notchapplez/unin/blob/main/src/gleam.rs): `src/gleam.rs`
- [Haskell builder](https://github.com/notchapplez/unin/blob/main/src/haskell.rs): `src/haskell.rs`

### System and registry

- [Toolchain setup](https://github.com/notchapplez/unin/blob/main/src/installer.rs): `src/installer.rs`
- [Binary installation](https://github.com/notchapplez/unin/blob/main/src/tools.rs): `src/tools.rs`
- [Package registry](https://github.com/notchapplez/unin/blob/main/src/registry.rs): `src/registry.rs`
- [Build logs](https://github.com/notchapplez/unin/blob/main/src/logging.rs): `src/logging.rs`

### Other components

- **CLI user**
- **Linux system**
- **Package managers**

## Connections

- CLI user → Command entry: invokes
- Command entry → Package registry: checks registry
- Command entry → Detect and route: detects project
- Command entry → Git fetch: fetches URL
- Command entry → Toolchain setup: sets up tools
- Command entry → Detect and route: dispatches clean
- Command entry → Package registry: lists or uninstalls
- Detect and route → CMake builder: dispatches
- Detect and route → Make builder: dispatches
- Detect and route → Configure builder: dispatches
- Detect and route → Meson builder: dispatches
- Detect and route → Rust builder: dispatches
- Detect and route → Go builder: dispatches
- Detect and route → Zig builder: dispatches
- Detect and route → Gleam builder: dispatches
- Detect and route → Haskell builder: dispatches
- Detect and route → CMake builder: cleans
- Detect and route → Make builder: cleans
- Detect and route → Configure builder: cleans
- Detect and route → Meson builder: cleans
- Detect and route → Rust builder: cleans
- Detect and route → Go builder: cleans
- Detect and route → Zig builder: cleans
- Detect and route → Gleam builder: cleans
- Detect and route → Haskell builder: cleans
- Rust builder → Binary installation: installs binaries
- CMake builder → Package registry: registers binaries
- Configure builder → Package registry: registers binaries
- Meson builder → Package registry: registers binaries
- Gleam builder → Package registry: registers package
- Make builder → Package registry: registers installs
- Binary installation → Linux system: copies to bin
- Package registry → Linux system: reads and writes files
- Package registry → Linux system: deletes package files
- Command entry → Build logs: logs
- Toolchain setup → Package managers: installs packages
