# patons02/hydejack-theme architecture

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

- Interactive diagram: https://gitdiagram.com/patons02/hydejack-theme
- Repository: https://github.com/patons02/hydejack-theme

## Overview

##### Project type and purpose
- This is a Jekyll-based “starter kit” for building a static blog (Hydejack Starter Kit).
- Purpose: provide a folder structure, templates, styles, docs, and example posts to accelerate spinning up a Jekyll site.

##### File structure
- Top-level directories:
- .bundle, Gemfile → Ruby/Bundler environment
- .github/workflows → CI pipeline (jekyll build/test)
- _config.yml → global Jekyll configuration
- _includes, _sass → partial templates & SASS styles
- _data → site-wide YAML data (authors, social links, strings)
- _featured_categories → content snippets
- assets/img → static images for blog/docs
- docs → detailed user/developer documentation
- example/_posts → sample markdown posts
- index.html, about.md, posts.md → top-level pages
- Patterns:
- Jekyll static-site generator pipeline (Liquid templates + front-matter in markdown)
- SASS build for CSS
- GitHub Actions for CI/deploy

##### Key README insights
- Build steps: bundle install → bundle exec jekyll serve
- Deployment target: likely GitHub Pages or any static host
- Encourages reading the docs/ folder for advanced configuration

##### Main components
a. Content & Source layer
- Markdown files (_posts, *.md)
- YAML data files (_data)
- Template partials (_includes)
- SASS files (_sass)
- Config (_config.yml)
b. Build & Tooling layer
- Ruby + Bundler + Gems
- Jekyll engine (Liquid renderer)
- SASS compiler
- GitHub Actions workflow
c. Output & Deployment layer
- Generated static site (_site)
- Hosting (GitHub Pages or static-site host)
d. External services
- Hydejack PRO download site (optional)
- npm/rubygems registry (for dependencies)

##### Relationships and interactions
- Developer commits source files → Git → GitHub
- On push, GitHub Actions runs `bundle install` + `jekyll build`
- YAML + Markdown + Liquid templates + SASS → Jekyll/SASS compilers → `_site` (HTML/CSS/JS)
- CI job then deploys `_site` to GitHub Pages (or other host)
- Browser requests files from host → serves static content

##### Architectural patterns & design principles
- Static-site generator pipeline (no runtime backend)
- Clear separation between content (markdown/YAML), presentation (Liquid + includes), and styling (SASS)
- Convention-over-configuration via `_config.yml` and directory names
- CI/CD integration for automated build & deploy

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% Content & Source Layer
    subgraph "Content & Source Layer"
        direction TB
        TopPages["Top-level Pages\n(404.md, about.md,\nposts.md, index.html)"]:::source
        ExamplePosts["Example Posts\n(example/_posts/*.md)"]:::source
        Data["YAML Data\n(_data)"]:::source
        Templates["Template Partials\n(_includes)"]:::source
        Styles["SASS Styles\n(_sass)"]:::source
        Config["Config File\n(_config.yml)"]:::source
    end

    %% Build & Tooling Layer
    subgraph "Build & Tooling Layer"
        direction TB
        RubyEnv["Ruby/Bundler\n(Gemfile, .bundle/, .ruby-version)"]:::tooling
        JekyllEngine["Jekyll Engine\n(liquid renderer)"]:::tooling
        SASSCompiler["SASS Compiler"]:::tooling
        CI["CI/CD Pipeline\n(.github/workflows/jekyll.yml)"]:::tooling
    end

    %% Documentation & Licensing
    subgraph "Documentation"
        direction TB
        Docs["Docs Folder\n(docs/)"]:::docs
    end

    subgraph "Licensing"
        direction TB
        Licenses["Licenses\n(licenses/)"]:::docs
    end

    %% Output & Deployment Layer
    subgraph "Output & Deployment Layer"
        direction TB
        Site["_site\n(Generated HTML/CSS)"]:::output
        Host["GitHub Pages\n(Static Host)"]:::external
        Browser["Browser\n(End-user)"]:::external
    end

    %% External Registries
    subgraph "External Services"
        direction TB
        Rubygems["RubyGems / npm\n(Dependencies)"]:::external
        PROSite["Hydejack PRO Site"]:::external
    end

    %% Flows
    TopPages & ExamplePosts & Data & Templates & Styles & Config -->|“source files”| RubyEnv
    RubyEnv -->|“bundle exec jekyll build”| JekyllEngine
    Data & Templates & Config -->|“feeds”| JekyllEngine
    Styles -->|“compile”| SASSCompiler
    JekyllEngine & SASSCompiler -->|“output”| Site
    CI -->|“triggers build & deploy”| RubyEnv
    CI -->|“deploy”| Site
    Site -->|“hosted content”| Host
    Host -->|“HTTP request”| Browser
    Rubygems -->|“provides gems”| RubyEnv
    PROSite -.->|“optional download”| TopPages

    %% Click Events
    click TopPages "https://github.com/patons02/hydejack-theme/blob/master/_posts/404.md"
    click ExamplePosts "https://github.com/patons02/hydejack-theme/tree/master/example/_posts"
    click Data "https://github.com/patons02/hydejack-theme/tree/master/_data"
    click Templates "https://github.com/patons02/hydejack-theme/tree/master/_includes"
    click Styles "https://github.com/patons02/hydejack-theme/tree/master/_sass"
    click Config "https://github.com/patons02/hydejack-theme/blob/master/_config.yml"
    click RubyEnv "https://github.com/patons02/hydejack-theme/tree/master/Gemfile"
    click RubyEnv "https://github.com/patons02/hydejack-theme/tree/master/.bundle/"
    click RubyEnv "https://github.com/patons02/hydejack-theme/blob/master/.ruby-version"
    click CI "https://github.com/patons02/hydejack-theme/blob/master/.github/workflows/jekyll.yml"
    click Docs "https://github.com/patons02/hydejack-theme/tree/master/docs/"
    click Licenses "https://github.com/patons02/hydejack-theme/tree/master/licenses/"

    %% Styles
    classDef source fill:#D6EAF8,stroke:#2980B9,color:#154360
    classDef tooling fill:#D5F5E3,stroke:#27AE60,color:#145A32
    classDef output fill:#FCF3CF,stroke:#F1C40F,color:#7D6608
    classDef external fill:#E5E8E8,stroke:#7F8C8D,color:#2C3E50
    classDef docs fill:#FADBD8,stroke:#E74C3C,color:#641E16
```
