$ show SwiftOldDriver/iOS-Weekly
This repository is the official archive and static site for '老司机 iOS 周报' (Senior Driver iOS Weekly), a long-running curated newsletter for iOS developers. The project spans from 2018 to the present (2026) and contains over 380 weekly issues stored as structured Markdown files. While the core content is a curated list of articles, tools, and news, the repository also includes a build pipeline and a single-page application (SPA) that generates a searchable, full-text archive deployed to GitHub Pages. The architecture is a hybrid of content repository and static site generator: the `scripts/build-index.js` script parses the Markdown files, extracts metadata (sections, recommenders, reading time), and builds a search index using MiniSearch with CJK tokenization. The `docs/` directory contains the resulting SPA (`app.js`, `index.html`) and vendored libraries. The CI workflow (`.github/workflows/pages.yml`) automates building and deploying. The project is community-driven, with contributions submitted via GitHub Issues. It is actively maintained with recent updates, and the codebase is focused on reliable content delivery rather than complex application logic.
The LLM identified 3 files worth highlighting for reuse:
A Node.js script that scans the repository's Markdown files (reports, posts, contributors), extracts structured metadata (e.g., sections, recommenders, reading time), and builds a full-text search index using MiniSearch. It demonstrates a reusable pattern for turning a collection of markdown documents into a searchable archive, handling CJK tokenization and diverse content models. Although the file paths are specific to this project, the architecture (parse -> extract -> index) is easily adaptable to other static content sites.
A GitHub Actions workflow that automates the build and deployment of the static site to GitHub Pages. It installs Node.js, runs `npm run build` (which invokes `build-index.js`), and then deploys the `docs/` directory to Pages. It defaults to a self-hosted runner with GNU tar. This is a standard but clean example of a CI pipeline for a static site generator, and the pattern (install dependencies, build, deploy) is reusable for any similar project.
A single-file SPA that provides a hash-based router, markdown rendering (via Marked), and full-text search (via MiniSearch). It lazy-loads content from `index.json` and `search.json` generated by the build script. The application is self-contained, responsive, and includes features like dark mode and keyboard shortcuts. While the content loading is specific to the project's data format, the SPA architecture and search integration can serve as a reference for building a static site with client-side search.