# jelenkee/dotfiles architecture

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

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

## Overview

##### Project Type and Purpose
- This is a dotfiles repository for bash. It provides custom shell configurations (e.g., prompt enhancements with git status, execution time display) and a variety of aliases and functions.
- It also includes configurations for additional tools/editors (e.g., “micro” and “yazi”) and local binaries along with utility scripts.
- The README shows that the main workflow is for a user to clone the repo, run the setup (via setup.sh), and then let the system source the bash configuration from these files.

##### File Structure Analysis
- .config Directory:
- Contains tool-specific configurations.
- The “micro” folder holds configuration files (bindings.json, settings.json) for the Micro editor.
- The “yazi” folder contains various settings (theme.toml, keymap, plugin files) for another tool/editor.
- .local Directory:
- Contains a “bin” directory with custom executables (e.g., _df_zz) that likely support the shell’s extended functionality.
- .scripts Directory:
- Houses multiple shell scripts (e.g., alias.sh, cd.sh, prompt.sh) that implement the custom functions and initialization logic for the enhanced bash environment.
- Top-level files:
- The Makefile and README, and possibly a setup script (as referenced in the README, although the file isn’t directly shown here), which tie the entire configuration together using GNU Stow.

- Shell Environment (Bash):
- As the primary execution environment where the dotfiles are sourced.
- GNU Stow / Setup Utility:
- Role of configuration management where the dotfiles are organized and symlinked into the user’s home directory.
- Configuration Files:
▪ Micro Editor Config (.config/micro)
▪ Yazi Editor Config (.config/yazi)
- Custom Scripts:
- A component representing the .scripts directory where various helper scripts (aliasing, directory navigation, prompt configuration, etc.) are defined.
- Local Binaries:
- The .local/bin directory which holds executable utilities like custom search tools (z, zz).

##### Architectural Patterns and Relationships
- The design shows clear separation between the configuration for different tools (editors) and the core bash configuration.
- The scripts and local binaries act as modular extensions that influence the behavior of the bash shell.
▪ Configuration Flow: Show that tool-specific configurations (.config/micro and .config/yazi) are used by their respective applications within the broader developer tooling ecosystem.

## Diagram (Mermaid)

```mermaid
graph TD
    %% Main Components
    bashShell["Bash Shell"]:::environment
    gnuStow["GNU Stow/Setup Utility"]:::setup
    shellScripts[".scripts: Shell Customizations"]:::scripts
    localBins[".local/bin: Local Binaries"]:::binaries

    %% Editor Configurations Subgraph
    subgraph "Editor Configurations"
        microConfig[".config/micro: Micro Editor Config"]:::config
        yaziConfig[".config/yazi: Yazi Editor Config"]:::config
    end

    %% Relationships
    gnuStow -->|"symlinks"| bashShell
    bashShell -->|"sources"| shellScripts
    bashShell -->|"executes"| localBins
    bashShell -->|"invokes"| microConfig
    bashShell -->|"invokes"| yaziConfig

    %% Click Events
    click gnuStow "https://github.com/jelenkee/dotfiles/tree/main/Makefile"
    click microConfig "https://github.com/jelenkee/dotfiles/tree/main/.config/micro"
    click yaziConfig "https://github.com/jelenkee/dotfiles/tree/main/.config/yazi"
    click shellScripts "https://github.com/jelenkee/dotfiles/blob/main/.scripts"
    click localBins "https://github.com/jelenkee/dotfiles/tree/main/.local/bin"

    %% Styles
    classDef environment fill:#ffeb3b,stroke:#333,stroke-width:2px;
    classDef setup fill:#8bc34a,stroke:#333,stroke-width:2px;
    classDef config fill:#03a9f4,stroke:#333,stroke-width:2px;
    classDef scripts fill:#ff9800,stroke:#333,stroke-width:2px;
    classDef binaries fill:#e91e63,stroke:#333,stroke-width:2px;
```
