# yebt/jumyneco architecture

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

- Interactive diagram: https://gitdiagram.com/yebt/jumyneco
- Repository: https://github.com/yebt/jumyneco

## Overview

This project is a Neovim configuration repository. Its purpose is to provide a customizable, modular setup for Neovim using Lua, which includes various plugin configurations, file type customizations, and integrated utilities like snippets and tree-sitter queries. The repository structure is organized to separate core configuration, plugins, filetype-specific settings, and additional helper resources.

##### Main Components
- Core Neovim Configuration:
- Files such as init.lua and lua/krnl.lua form the entry points.
- The lua/config directory contains configuration scripts for auto commands, keymaps, options, and the lazy loading mechanism.
- Plugin Management & Configuration:
- The lua/plugins directory holds plugin configurations, specs, and initialization scripts.
- Subfolders like lua/plugins/configs and lua/plugins/inits indicate that plugins are modularized by their configuration details.
- The plugin specs (in lua/plugins/specs) describe detailed setups for individual functionalities such as LSP, git, and UI, making it easier to track plugin interactions.
- Modular Components and Utilities:
- The lua/util folder (e.g., mapactions.lua) provides common utility functions.
- Filetype Specific Customizations ("after" Directory):
- The after folder includes filetype-specific options and tree-sitter queries (e.g., for markdown, php, lua, blade, smarty), indicating that specific optimizations or settings are applied post-initialization for certain filetypes.
- Additional Resources:
- The skeletons, snippets, templates, and spell directories provide starter files, snippet definitions, and templates that enhance the editing experience.

##### Relationships and Interactions
- The Neovim startup (triggered via init.lua) loads the configuration from lua/config, which sets up global options, auto commands, and key mappings.
- Early in the startup process, lazy loading via lua/config/lazy.lua is initialized to manage dynamic plugin loading.
- The plugin system (from lua/plugins) interacts with both the core config and modules. It handles plugin-specific configurations, initialization routines (in lua/plugins/inits), and detailed specification in lua/plugins/specs.
- After the core configurations, filetype customizations in the "after" directory are applied. They override or append settings for specific filetypes and embed tree-sitter queries, which enhance syntax highlighting and code injections.
- Documentation and notes in the doc directory provide human-readable guidance and extra context, while the README offers links to similar projects and suggestions (e.g., nvim by glepnir and plugins like template.nvim and dbsession.nvim) for extending functionality.

##### Architectural Patterns and Design Principles
- Modularity: Separation between core configuration, plugins, and filetype-specific settings allows easy extension and maintainability.
- Lazy Loading: The configuration supports lazy loading so that plugins are initialized only when needed, reducing startup overhead.
- Separation of Concerns: Clear split between configuration logic (lua/config), plugin settings (lua/plugins), and reusable modules (lua/modules) keeps the codebase clean and focused.
- Extensibility: Directories like skeletons, snippets, and templates show that the architecture is designed for user customization and providing starting points for various languages and frameworks.

##### Relevant Technologies and Frameworks
- Neovim as the runtime and editor.
- Lua as the programming language for configuration.
- Tree-sitter queries for advanced syntax highlighting and language parsing (located in the after/queries directory).
- Lazy-loading mechanism as configured from lazy.lua.
- Plugin systems adapted to Neovim ecosystems (reflected by the presence of various plugin config files).
- External references (e.g., links provided in the README) indicate use of community-tested plugins like template.nvim and dbsession.nvim.

##### Instructing the Principal Software Engineer
- A different style for plugin configuration (lua/plugins).
- Another distinct style for filetype-specific customization (after folder).
- That you capture all the essential architectural elements:
- The modularity and extensibility of the design;
- The lazy-loading strategy and separation of concerns;
- The integration of syntax highlighting and language-specific customizations via tree-sitter queries.

## Diagram (Mermaid)

```mermaid
flowchart TD
    subgraph "Core Configuration"
        init("init.lua"):::core
        krnl("lua/krnl.lua"):::core
        config("lua/config"):::core
        lazy("lua/config/lazy.lua"):::core
        init --> config
        krnl --> config
        config --> lazy
    end

    subgraph "Plugin Management"
        plugins("lua/plugins"):::plugin
        plugins_configs("lua/plugins/configs"):::plugin
        plugins_inits("lua/plugins/inits"):::plugin
        plugins_specs("lua/plugins/specs"):::plugin
        lazy --> plugins
        plugins --> plugins_configs
        plugins --> plugins_inits
        plugins --> plugins_specs
    end

    subgraph "Modules and Utilities"
        modules("lua/modules"):::module
        util("lua/util/mapactions.lua"):::module
        config --> modules
        config --> util
    end

    subgraph "Filetype Customizations"
        ftplugin("after/ftplugin"):::after
        queries("after/queries"):::after
        lazy --> ftplugin
        ftplugin --> queries
    end

    subgraph "Additional Resources"
        skeletons("skeletons"):::resource
        templates("templates"):::resource
        snippets("snippets"):::resource
        spell("spell"):::resource
        doc("doc"):::resource
        config --> doc
    end

    %% Styles
    classDef core fill:#ffcccc,stroke:#cc0000,stroke-width:2px;
    classDef plugin fill:#ccffcc,stroke:#006600,stroke-width:2px;
    classDef module fill:#ccccff,stroke:#0000cc,stroke-width:2px;
    classDef after fill:#ffcc99,stroke:#ff6600,stroke-width:2px;
    classDef resource fill:#ffffcc,stroke:#cccc00,stroke-width:2px;

    %% Click Events
    click init "https://github.com/yebt/jumyneco/blob/main/init.lua"
    click krnl "https://github.com/yebt/jumyneco/blob/main/lua/krnl.lua"
    click config "https://github.com/yebt/jumyneco/tree/main/lua/config"
    click lazy "https://github.com/yebt/jumyneco/blob/main/lua/config/lazy.lua"
    click plugins "https://github.com/yebt/jumyneco/tree/main/lua/plugins"
    click plugins_configs "https://github.com/yebt/jumyneco/tree/main/lua/plugins/configs"
    click plugins_inits "https://github.com/yebt/jumyneco/tree/main/lua/plugins/inits"
    click plugins_specs "https://github.com/yebt/jumyneco/tree/main/lua/plugins/specs"
    click modules "https://github.com/yebt/jumyneco/tree/main/lua/modules"
    click util "https://github.com/yebt/jumyneco/blob/main/lua/util/mapactions.lua"
    click ftplugin "https://github.com/yebt/jumyneco/tree/main/after/ftplugin"
    click queries "https://github.com/yebt/jumyneco/tree/main/after/queries"
    click skeletons "https://github.com/yebt/jumyneco/tree/main/skeletons"
    click templates "https://github.com/yebt/jumyneco/tree/main/templates"
    click snippets "https://github.com/yebt/jumyneco/tree/main/snippets"
    click spell "https://github.com/yebt/jumyneco/tree/main/spell"
    click doc "https://github.com/yebt/jumyneco/tree/main/doc"
```
