Promoted, project-specific knowledge for agents working in this repo. Items
here are reviewed and approved via /reflect (sourced from REFLECTION.md).
Read this at the start of every session.
- CSV header source-of-truth: When a CSV file gets its header from an
explicit
echo "..." > "$FILE", every subsequentwp post list ... >> "$FILE"append MUST pipe throughtail -n +2to drop WP-CLI's own header. Local and remote branches must be symmetric on this. The Perl merge skips only ONE header line, and theawk 'NF == cols'validation won't catch a header-shaped junk row (it has a valid field count). (PR #3, 2026-06-11)
-
Adding/removing an export column ripples across ~6 coordinated sites in
export_wp_posts.sh. Audit all of them: both the local AND remote WP-CLI--fields=lists, the CSV headerecho,EXPECTED_COLUMNS(static default- dynamic
$((... ))), the Perl field-count guard + field indices, theMERGE_HEADER, and the Excel column offsets (DATE_COL/STATUS_COL/etc.). (PR #3, 2026-06-11)
- dynamic
-
Multi-branch shell pipelines (local vs remote): Diff the branches against each other first. Asymmetries between paths that "should" behave identically are where latent bugs hide. (PR #3, 2026-06-11)