$ show timqian/chinese-independent-blogs
This repository is a curated, community-maintained list of Chinese independent blogs. The primary data asset is a CSV file (`blogs-original.csv`) containing blog names, URLs, RSS feed URLs, and tags. The repository includes a set of Python utility scripts (`linter.py`, `readme_render.py`, `opml_generator.py`) that validate the CSV data, generate the README markdown, and produce an OPML feed export. These are orchestrated via GitHub Actions on push and weekly cron. The project is not a software application or a data pipeline in the traditional sense; it is a data curation project with tightly coupled orchestration scripts. The value lies in the curated dataset and the reproducibility of the derived outputs (README and OPML). The codebase is simple but well-engineered for its purpose: validation is thorough, transformations are idempotent, and CI ensures data integrity. This repository serves as a canonical reference for Chinese independent blogs and can be reused by other curation projects looking for a structured CSV-to-markdown/OPML workflow.
The LLM identified 3 files worth highlighting for reuse:
A reusable CSV validation script that checks for common data integrity issues: column presence, leading/trailing whitespace, duplicate entries, URL format, tag separator correctness, and newline endings. It uses a defensive parsing strategy and provides clear error messages with row numbers. This pattern can be extracted and applied to any curated CSV dataset where data cleanliness is critical (e.g., community lists, directories). The script is self-contained, requires only Python's standard library (`csv`), and can be run as a standalone linter.
A lightweight Python script that reads the CSV and outputs a formatted Markdown table. It demonstrates a clean pattern for generating documentation from structured data: it prints the static header and footer, then iterates over CSV rows to produce table rows. The script is idempotent and can be easily adapted for any dataset that needs a Markdown table representation. It uses `csv.DictReader` for clarity and prints directly to stdout, making it composable in shell pipelines (e.g., `python readme_render.py > README.md`).
A simple but effective script that converts the CSV blog list into an OPML (Outline Processor Markup Language) feed. It constructs the XML manually using string formatting and `quoteattr` for proper attribute escaping, producing a valid OPML 1.0 document. This pattern is reusable for any curated list of RSS feeds that needs an OPML export for feed reader subscriptions. The script is concise, uses only standard library modules, and demonstrates a low-dependency approach to XML generation.