Skip to content

Instantly share code, notes, and snippets.

@MuhammadAashirAslam
Last active August 24, 2026 02:54
Show Gist options
  • Select an option

  • Save MuhammadAashirAslam/a5c5929b962d0a0886a4f050279fcade to your computer and use it in GitHub Desktop.

Select an option

Save MuhammadAashirAslam/a5c5929b962d0a0886a4f050279fcade to your computer and use it in GitHub Desktop.
Google Summer of Code 2026 — Final Work Submission

Google Summer of Code 2026 — Final Work Submission

Resource Details
Organization preCICE
Project Title Website Modernization: Migration from Jekyll to Hugo
Contributor Muhammad Aashir Aslam (@aashiraslam:matrix.org)
Mentors Gerasimos Chourdakis, Frédéric Simonis
Primary Repository precice/precice.github.io
Active Migration Branch hugo

1. Executive Summary & Project Abstract

The preCICE documentation and community website serves as the central hub for the preCICE coupling ecosystem, hosting solver adapter guides, coupling tutorials, reference documentation, community stories, and project announcements.

Historically, the website was built on Jekyll (Ruby) and depended on an aging chain of Ruby gems and custom Ruby plugins for submodule documentation harvesting. This created setup friction for open-source contributors due to local Ruby/Bundler environments and native C-extension compilation steps, alongside slow feedback loops during local editing. Furthermore, the user interface relied on Bootstrap 3.3.7 (dating back to 2016) and jQuery.

The objective of this Google Summer of Code project was to perform a complete, zero-downtime modernization of the website by migrating to Hugo (a fast, single-binary static site generator) and upgrading the frontend to modern Bootstrap 5.3.8 while removing jQuery entirely. All existing features—including documentation mounts from external repositories, Algolia search indexing, RSS feeds, Discourse forum synchronization, and offline PDF generation—were faithfully ported, modernized, and verified with zero regressions in feature set or URL structure.

All planned project milestones (M0: Baseline & Audit, M1: Core Hugo & Bootstrap 5, M2: Module Mounts & Search, M3: CI/CD & Final Cutover) were fully achieved and delivered.

Key Outcomes by Topic

  • Modern Hugo-Based Website Architecture: Ported the entire site to Hugo Go templates, establishing a modular layout hierarchy (layouts/_default/, layouts/partials/, layouts/shortcodes/) that delivers fast local development and instant live reloading.
  • Modern Bootstrap 5 Frontend: Upgraded the UI from Bootstrap 3.3.7 to accessible, responsive Bootstrap 5.3.8 and native Vanilla JavaScript, eliminating jQuery completely.
  • Native Sub-Repository Documentation Ingestion: Replaced custom Ruby harvesting scripts with Hugo's declarative [[module.mounts]] system, enabling adapter repositories to mount their documentation directly into the site tree.
  • Algolia Search Indexing Pipeline: Replaced the legacy jekyll-algolia gem with native Hugo JSON export generation (public/algolia.json) and a lightweight, custom Node.js script for atomic Algolia index updates.
  • High-Fidelity PDF Generation Pipeline: Re-implemented the Prince XML compilation script (tools/pdf-docs.sh) and print stylesheet (printstyles.css) to generate a complete offline single-volume PDF manual (pdf/docs.pdf) with automated table of contents and dynamic page counters.
  • Automated CI/CD & Community Sync Workflows: Rewrote GitHub Actions workflows for testing, GitHub Pages deployment, Hugo module sync, and daily Discourse news/FAQ data updates with rate-limit protection and excerpt caching.
  • Clean Dependency Footprint: Removed all legacy Ruby gems, Gemfile, and custom plugins in favor of a single pre-compiled Hugo binary.

2. Project Architecture & Technical Implementation

Jekyll Legacy Architecture (Before)
┌─────────────────────────────────────────────────────────────┐
│ Markdown Content + 10 Submodules (via custom subprojects.rb)│
├─────────────────────────────────────────────────────────────┤
│ Ruby Gemchain: posix-spawn, jekyll-algolia, nokogiri, Sass  │
├─────────────────────────────────────────────────────────────┤
│ Jekyll Engine + Liquid Templates + Bootstrap 3 + jQuery     │
└─────────────────────────────────────────────────────────────┘
                              ▼
Hugo Modern Architecture (Delivered)
┌─────────────────────────────────────────────────────────────┐
│ Content Sections + Hugo Module Mounts ([[module.mounts]])   │
├─────────────────────────────────────────────────────────────┤
│ Pure Hugo Extended Binary (Go Engine) + Native Git Info     │
├─────────────────────────────────────────────────────────────┤
│ Go HTML Templates + Bootstrap 5.3.8 (Vanilla JS & CSS)      │
├─────────────────────────────────────────────────────────────┤
│ Outputs: HTML + Algolia JSON + RSS Feeds + Prince/PDF Docs  │
└─────────────────────────────────────────────────────────────┘

Technical Pillars

  1. Template & Partial Engine Migration:

    • Ported 27 Liquid includes to organized Hugo partials (core/, nav/, community/, publications/, alerts/, utilities/, integrations/).
    • Converted 7 top-level Jekyll layouts to Hugo layouts (single.html, list.html, page.html, and specialized templates for publications, testimonials, and XML reference tables).
    • Authored custom Hugo shortcodes ({{< note >}}, {{< tip >}}, {{< warning >}}, {{< figure >}}, {{< pagebreak >}}, {{< youtube >}}) to replace Liquid tag constructs.
  2. External Documentation via Module Mounts:

    • Replaced manual submodule sync hooks with native Hugo [[module.mounts]] configurations in config/_default/module.toml.
    • Enabled adapter and tooling repositories to be mounted directly into their target content paths without file copying.
  3. Search Engine Modernization (Algolia):

    • Created a custom Hugo output format (Algolia, producing public/algolia.json) structured specifically for searchable record chunking.
    • Built a Node.js tool (tools/algolia-index.mjs) featuring HTML element filtering (headings, paragraphs, tables, code blocks), callout exclusion, and atomic replaceAllObjects updates via Algolia API v5.
  4. Automated Discourse & Ecosystem Data Updates:

    • Replaced Liquid plugins with standard-library Python scripts (tools/fetch-faq.py, tools/fetch-news.py) to fetch community news and FAQs from the preCICE Discourse forum.
    • Added last_posted_at caching, User-Agent headers, rate-limit backoffs, and a 50-view diff threshold to eliminate unnecessary daily timestamp-only git commits.
  5. Print Styles & Offline PDF Documentation:

    • Re-engineered tools/pdf-docs.sh and static/css/printstyles.css for Prince XML to compile the entire documentation suite into pdf/docs.pdf.
    • Resolved styling edge-cases including badge alignment, responsive tables, KaTeX/MathJax compatibility, and cross-section page counting.

3. Performance & Contributor Experience (Before vs. After)

Metric Jekyll (Before GSoC) Hugo (Delivered) Improvement
Local Contributor Setup Ruby runtime + Bundler + Gem C-extensions (Nokogiri, FFI) Pre-compiled Hugo binary (hugo server) Zero Build Environment Friction
Frontend Framework Bootstrap 3.3.7 + jQuery (2016) Bootstrap 5.3.8 + Vanilla JS Modern, Accessible & Lightweight
External Doc Ingestion Custom Ruby scripts (subprojects.rb) Declarative [[module.mounts]] Native & Robust
Search Indexing jekyll-algolia (abandoned Ruby gem) Native Hugo JSON Output + Node.js Zero Ruby Dependency
Last Modified Tracking jekyll-last-modified-at gem Native enableGitInfo = true Built-in Git Integration

4. Challenges & Key Learnings

Technical Challenges

  1. Jumping Two Major Bootstrap Generations (3.3.7 → 5.3.8):

    • Challenge: Upgrading directly across two major framework versions broke grid classes (col-xs-* replaced by col-*), panels (replaced by cards), and data attributes (data-toggle → data-bs-toggle), alongside the total elimination of jQuery.
    • Resolution: Audited all 27 partials and custom Markdown inclusions to systematically replace legacy components with native Bootstrap 5 flexbox utilities and accessible attributes.
  2. Cross-Repository Documentation Mounting & Link Resolution:

    • Challenge: External documentation repositories mounted via Hugo modules contained relative Markdown links and legacy Jekyll permalinks that broke under Hugo's strict URL model.
    • Resolution: Coordinated cross-repository updates to standardize link targets, and implemented a custom Hugo link render hook (layouts/_markup/render-link.html) alongside a fuzzy page resolution helper (layouts/partials/pdf/page-for-url.html) to dynamically resolve cross-section permalinks and anchor targets.
  3. Print & PDF Styling Edge Cases:

    • Challenge: Prince XML rendering for compiled offline manuals caused badge buttons (DOI, JOSS) to stretch across full lines and broke external link markers.
    • Resolution: Authored universal print CSS rules in printstyles.css ensuring inline-block alignment, relative nav tab counters, high-contrast code headers, and complete suppression of external link pseudo-elements on images.

Key Learnings

  1. Atomic PRs & Structured Git Workflows:
    • Managing a large-scale migration taught me how to decompose massive architectural changes into focused, reviewable pull requests. I gained deep experience with advanced Git operations—managing stacked branches, rebasing across fast-moving upstream commits, and keeping commit histories clean and atomic per review comment.
  2. Open Source Code Review Culture & Communication:
    • The regular online standup meetings with my mentor, Gerasimos Chourdakis, were invaluable—not only for resolving complex technical roadblocks and aligning on architectural trade-offs, but also for fostering my communication skills in a professional open-source environment. Engaging in constructive GitHub reviews and weekly video discussions taught me how to articulate technical ideas clearly, iterate productively on feedback, and collaborate effectively within a distributed engineering team.
  3. Cross-Repository Ecosystem Coordination:
    • Contributing to preCICE expanded my perspective beyond a single repository. Coordinating module mounts, link structures, and permalink aliases across multiple solver adapter repositories emphasized the importance of clear developer documentation and backward compatibility for distributed open-source teams.

5. Current Project Status & Verification

Parity Verification

Parity between the legacy Jekyll site and the new Hugo site was rigorously checked across multiple layers:

  • Automated CI Validation: Integrated xmllint in CI to validate the syntax and integrity of sitemap.xml, sitemap_index.xml, and feed.xml.
  • URL & Redirect Verification: Verified that all 339 documentation pages, 239 aliases/redirects, and section index pages resolve without broken links or missing assets, auditing link integrity across the ecosystem (#943).
  • Search Output Validation: Verified that public/algolia.json correctly generates 10,600+ structured search records matching the exact schema and ranking expectations of Algolia v5.
  • Offline PDF Generation: Verified that ./tools/pdf-docs.sh runs cleanly and compiles all sections into a complete pdf/docs.pdf volume.

Current Status

  • The complete Hugo site is fully implemented, verified, and operational on the hugo branch.
  • Final PR reviews (Algolia search, content documentation, PDF pipeline, and the final Jekyll cutover) are in progress to complete the transition to master.

Future Work & Opportunities

  • Dark Mode Support: Leverage Bootstrap 5's native color mode infrastructure (data-bs-theme="dark") and CSS variables to provide a seamless dark theme toggle for documentation readers.
  • Enhanced Footer Layout: Design and implement a modern, multi-column footer featuring quick documentation navigation, ecosystem links, community channels, and institutional acknowledgements.
  • Automated URL Regression Testing: Integrate an automated crawler in CI to verify that future documentation edits do not introduce broken cross-references.
  • Hugo Asset Image Processing: Utilize Hugo’s built-in WebP image pipeline to automatically optimize large tutorial screenshots for faster mobile page loads.
  • Multilingual Support: Leverage Hugo’s native i18n capabilities should community translations of core guides be introduced.

6. Summary of Pull Requests & Contributions

All development work was tracked on the preCICE Hugo Migration Project Board. Below is the topical breakdown of all 27 pull requests developed during the GSoC 2026 period:

Core Hugo Architecture & Migration
  • PR #944: Migrate Jekyll _layouts to Hugo layouts/_default [Core Architecture]
  • PR #945: Initialize Hugo config directory and split module mounts [Core Architecture]
  • PR #939: Add native section index markers [Core Architecture]
  • PR #941: Rename content files to remove unneeded prefixes [Content Architecture]
  • PR #964: Migrate content and static assets [Content Architecture]
  • PR #973: Jekyll Cutover: Delete legacy Jekyll files and finalize Hugo migration [Final Cutover]
Templates, Partials & Bootstrap 5 Modernization
  • PR #922: Migrate from Bootstrap 3.3.7 to Bootstrap 5.3.8 [Frontend / UI]
  • PR #950: Add core page layout partials [Templates]
  • PR #951: Add sidebar layouts [Templates]
  • PR #947: Add community and testimonial partials [Templates]
  • PR #948: Add publication and tagging partials [Templates]
  • PR #949: Add alert and callout partials [Templates]
  • PR #952: Add third party integrations and analytics partials [Templates]
  • PR #953: Add content utilities and helpers partials [Templates]
  • PR #961: Add Hugo shortcodes [Shortcodes]
  • PR #963: Add specialized Hugo layouts [Templates]
Search, Feeds & SEO Integration
  • PR #968: Add Hugo Algolia indexing [Search]
  • PR #966: Replace Jekyll XML Outputs and Update Doxygen Sitemap Integration [Feeds / SEO]
CI/CD Workflows & Discourse Automation
  • PR #967: Rewrite CI workflows for Hugo [CI/CD]
  • PR #969: Migrate Hugo module and Discourse workflows [Automation]
PDF Documentation Pipeline
  • PR #972: Port PDF generation to Hugo [PDF / Print]
  • PR #938: Limit PDF image height [Print] [Minor Fix]
Accessibility, UI Polish & Documentation
  • PR #935: Make embedded YouTube videos responsive [Minor Fix]
  • PR #936: Fix XML reference layout on mobile [Minor Fix]
  • PR #971: Update references to renamed edit button [Minor Fix]
  • PR #970: Update Hugo content documentation [Documentation]
  • PR #977: Rename tutorials sidebar data file and update Hugo configuration [Minor Fix]

7. Acknowledgements

I would like to express my deepest gratitude to my primary mentor, Gerasimos Chourdakis, whose exceptional mentorship, weekly standup meetings, detailed architectural reviews across every pull request, and steadfast guidance were instrumental in bringing this migration across the finish line. His prompt feedback, thoughtful insights, and supportive discussions made navigating complex technical challenges a rewarding learning journey.

I would also like to thank co-mentor Frédéric Simonis for supporting the project and providing feedback throughout the Google Summer of Code period.

Working with the preCICE organization has been an invaluable experience that sharpened my software engineering, static site architecture, and open-source collaboration skills. Special thanks to the entire preCICE developer community and the Google Summer of Code team for making this modernization project possible.


Muhammad Aashir Aslam
Islamabad, Pakistan
August 2026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment