feat: add one_to_rule article content and demo assets - #85
Open
Andreas-Garcia wants to merge 1 commit into
Open
Conversation
Adds the "one to rule them all" article: VHS tapes for before/after and side-by-side demos across ID3v1/ID3v2/Vorbis/RIFF, the hero video generation script, sample audio fixtures, and supporting docs. Fixes picked up along the way: - generate_one_to_rule_video.sh: fall back to assets/logo.png when logo-round.png is absent; corrected a stale scale comment - print_id3v1_tags.py: fixed missing space after the Comment: label - ensure_demo_read_id3v1.py: mask the synchsafe tag size's reserved high bit and account for the optional v2.4 footer when computing the ID3v2 strip offset Also removes the stale root-level audiometa_demo_twitter_final.mp4, superseded by this article's own assets.
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new content/articles/one_to_rule/ article project with VHS tapes and supporting scripts to generate a “hero” comparison video and side-by-side GIFs for unified metadata reading across RIFF/ID3v2/ID3v1/Vorbis. Also updates lint config and changelog entries related to these demo scripts/assets.
Changes:
- Add the
one_to_rulearticle structure (README/scenario docs, VHS tapes, and platform notes) undercontent/articles/. - Add scripts to generate the hero video and demo assets, plus helpers to create ID3v1-only demo files and sync sample metadata.
- Update Ruff per-file ignores for article scripts and update
CHANGELOG.mdentries for these demo tooling fixes.
Reviewed changes
Copilot reviewed 25 out of 30 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| pyproject.toml | Adds Ruff per-file-ignores for the article’s Python demo scripts. |
| content/articles/README.md | Documents the per-article directory structure and points to one_to_rule/. |
| content/articles/one_to_rule/VIDEO_SCENARIO_ONE_TO_RULE.md | Describes the hero video segment plan and regeneration guidance. |
| content/articles/one_to_rule/twitter/README.md | Notes which generated assets to use for the Twitter post. |
| content/articles/one_to_rule/tapes/write_then_read.tape | VHS demo: write tags then read back via audiometa unified. |
| content/articles/one_to_rule/tapes/read_vorbis_metaflac.tape | VHS demo: show Vorbis comments via metaflac. |
| content/articles/one_to_rule/tapes/read_vorbis_audiometa.tape | VHS demo: show Vorbis comments via audiometa unified. |
| content/articles/one_to_rule/tapes/read_id3v1_other.tape | VHS demo: show ID3v1 via a custom “other tool” printer script. |
| content/articles/one_to_rule/tapes/read_id3v1_audiometa.tape | VHS demo: show the same ID3v1-only file via audiometa unified. |
| content/articles/one_to_rule/tapes/get_full_metadata.tape | VHS demo: unified output in table/JSON/YAML formats (truncated). |
| content/articles/one_to_rule/tapes/before_only.tape | VHS half-width “before” panel for ID3v2 (mid3v2). |
| content/articles/one_to_rule/tapes/before_only_riff.tape | VHS half-width “before” panel for RIFF (ffprobe). |
| content/articles/one_to_rule/tapes/before_after_one_command.tape | VHS full-width “before vs after” demo (mid3v2 vs audiometa unified). |
| content/articles/one_to_rule/tapes/after_only.tape | VHS half-width “after” panel for ID3v2 (audiometa unified). |
| content/articles/one_to_rule/tapes/after_only_riff.tape | VHS half-width “after” panel for RIFF (audiometa unified). |
| content/articles/one_to_rule/scripts/sync_article_sample_metadata.py | Helper to sync canonical metadata across sample MP3/FLAC. |
| content/articles/one_to_rule/scripts/run_vhs_tape.sh | Runs a tape with @@ONE_TO_RULE_ABS@@ injection and venv enforcement. |
| content/articles/one_to_rule/scripts/run_demo_side_by_side.sh | Builds and hstacks the ID3v2 “before/after” GIFs into a final asset. |
| content/articles/one_to_rule/scripts/run_demo_side_by_side_vorbis.sh | Builds and hstacks the Vorbis “before/after” GIFs into a final asset. |
| content/articles/one_to_rule/scripts/print_id3v1_tags.py | Prints ID3v1 TAG fields for the “other tool” panel. |
| content/articles/one_to_rule/scripts/generate_one_to_rule_video.sh | End-to-end hero video builder: records/reuses GIFs, composes pages, concatenates MP4. |
| content/articles/one_to_rule/scripts/ensure_demo_read_id3v1.py | Produces an ID3v1-only MP3 demo file by stripping ID3v2/ID3v1 and re-tagging. |
| content/articles/one_to_rule/samples/README.md | Documents the sample binaries and how to keep metadata aligned. |
| content/articles/one_to_rule/README.md | Main article README: contents, build prerequisites, and commands. |
| CHANGELOG.md | Adds Unreleased entries for the demo script fixes and updates a .gitignore note. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+28
to
+40
| "$VENV_BIN/python3" -c " | ||
| from pathlib import Path | ||
| import sys | ||
|
|
||
| article_root = Path('$ARTICLE_ROOT').resolve() | ||
| tape = Path('$TAPE_PATH') | ||
| text = tape.read_text() | ||
| needle = '@@ONE_TO_RULE_ABS@@' | ||
| if needle not in text: | ||
| sys.stderr.write(f'Error: {needle!r} missing in {tape}\n') | ||
| sys.exit(1) | ||
| Path('$tmp').write_text(text.replace(needle, str(article_root))) | ||
| " |
| ### Documentation | ||
|
|
||
| - **Demo outputs in .gitignore**: Generated demo outputs (GIFs, MP4s, tape sources under docs/demos) excluded from version control; source tapes and final demo asset remain tracked. | ||
| - **Demo outputs in .gitignore**: Generated demo outputs (GIFs, MP4s, tape sources under content/articles/one_to_rule) excluded from version control; source tapes and final demo asset remain tracked. |
35 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
README.md,VIDEO_SCENARIO_ONE_TO_RULE.md,twitter/README.md)assets/logo.mp4intro logo used bygenerate_one_to_rule_video.shaudiometa_demo_twitter_final.mp4, superseded by this article's own assetspyproject.toml: article-specific ruff per-file-ignores forensure_demo_read_id3v1.py/print_id3v1_tags.pyBug fixes picked up along the way:
generate_one_to_rule_video.sh: falls back toassets/logo.pngwhenlogo-round.pngis absent; corrected a stale scale commentprint_id3v1_tags.py: fixed missing space after theComment:labelensure_demo_read_id3v1.py: masks the synchsafe tag size's reserved high bit and accounts for the optional v2.4 footer when computing the ID3v2 strip offsetWhy split from #80, and why stacked on #83
This is a focused slice of #80, which bundled unrelated concerns into a single PR. This article depends on the
content/demo/...paths and tooling introduced in #83 (refactor/content-demo-hub), so it's stacked on that branch rather thanmain.Type of change
Checklist
verify-system-dependency-versions, skipped locally — pinned mediainfo version is bumped in fix(ci): bump macOS mediainfo pin 26.01 -> 26.05 #81, unrelated to this PR's content)