Skip to content

Latest commit

 

History

History
105 lines (73 loc) · 3.85 KB

ARCHITECTURE.md

File metadata and controls

105 lines (73 loc) · 3.85 KB

Architecture overview

This document aims to give a simple overview of how this project is structured.

Interaction with other systems

The following figure illustrates which other services this project talks to.

sequenceDiagram
    participant sitegen as Chum Web Generator
    participant obs as Sailfish Open Build System
    participant repo as Sailfish Chum Repository
    participant ghp as GitHub Pages
    
    sitegen ->> obs: List Chum repositories
    
    loop for each repository
        sitegen ->> repo: Retrieve repository metadata
    end
    
    Note over sitegen: Generate static website
    
    sitegen ->> ghp: Upload generated website
    
Loading

Files

Python code

Contains the main function.

Contains functions for creating Atom feeds.

Contains the definitions of all settings that can be set via environment variables or command line options.

Contains dataclasses that define the structure of the metadata for a package. It also parses a single package.

Prints progress in the standard output

Planned utility that can download images from the internet to the local disk

Contains code for talking to OBS and dealing with the repository information

Generates the webpages using Jinja2 templates

Writes some statistics about apps to a Markdown file

Static website data (JavaScript/CSS/images)

Script for displaying a fallback image if loading an image in a <img> tag fails for some reason

Copy of Lunr.js, a JavaScript library for full-text search. Used for the search functionality.

Extra JavaScript used for displaying search results on the search page

Main style sheet

Over-engineered script to save user preferences in JavaScript. Depending on the preferences, style classes are added and removed, and objects are shown/hidden.

Really only used for the architecture selection on a package page.

Jinja2 Templates

The page skeleton template

Functions for adding meta tags to pages

The about page

A link to this page is present in the User-Agent, so that site administrators know who on earth is visiting them and why.

The home page with featured apps

Template page for details of a single application/package

Template page for lists of packages of any kind

Page displaying search results

File with macros to display a single list item of a package