Digital Product Release Builder - 15 Packaging and QA Utilities
Plainwork Studio, version 1.0.0

Fifteen small command-line tools that check a digital product folder and package it for
download. They run on Python 3.10 or newer using only the standard library. Nothing needs a
network connection and nothing is uploaded anywhere.

QUICK START (copy and paste into a terminal opened in this folder)

  python tools/release_report.py sample_product --out-dir /tmp/report
  python tools/create_manifest.py sample_product --out /tmp/manifest.json
  python tools/build_zip.py sample_product --out /tmp/demo.zip --root-name demo-pack
  python tools/verify_zip.py /tmp/demo.zip --manifest /tmp/manifest.json --root-name demo-pack

On Windows write the same commands with "python" and a folder of your choice instead of /tmp.

Run the bundled tests (optional, needs pytest):

  python -m pip install -r requirements.txt
  python -m pytest tests -q

WHAT IS INSIDE

  tools/            the 15 utilities plus two helper modules (_common.py, _schema.py)
  schema/           manifest.schema.json and release.schema.json
  templates/        LICENSE.template.txt for products that do not have a licence yet
  sample_product/   a tiny finished product (PDF, images, sound, video) with a release.json
  tests/            the test suite (71 tests)
  docs/MANUAL.md    every tool, every option, worked examples
  docs/RELEASE_CHECKLIST.md   a checklist to tick before you publish
  LICENSE.txt       what you may do with this kit

THE FIFTEEN TOOLS

  create_manifest.py        list every file with size, SHA-256 and kind in manifest.json
  validate_filenames.py     safe characters, length, reserved Windows names, case clashes
  build_zip.py              ZIP with sorted entries and fixed timestamps (identical every run)
  make_checksums.py         write or verify SHA256SUMS.txt
  check_license.py          licence present and complete; install a template; check a ZIP
  build_preview_index.py    static HTML page that shows your preview images and file list
  validate_file_counts.py   exactly the number of files you promised, per extension
  pdf_pages.py              PDF page counts against limits or exact promises
  check_images.py           pixel sizes and weight of PNG, JPEG, GIF, WebP, SVG
  check_audio.py            duration, sample rate and channels (WAV natively, others via ffprobe)
  check_video.py            duration and frame size (MP4 natively, others via ffprobe)
  validate_manifest.py      manifest against its JSON Schema and against the disk
  verify_zip.py             built ZIP against the manifest: missing, extra, changed, junk
  scan_placeholders.py      finds unfinished wording in text files
  release_report.py         runs everything listed in release.json and writes a report

OPTIONAL SOFTWARE

  pypdf (pip install pypdf)  reads every kind of PDF. Without it pdf_pages.py counts page
                             objects in the raw file, which fails on compressed PDFs.
  ffprobe (part of ffmpeg)   needed only for audio other than WAV and video other than
                             MP4/MOV. Put it on your PATH or pass --ffprobe /path/to/ffprobe.

Every tool prints a short summary, exits with 0 when everything passes, 1 when it found
problems and 2 when it was used incorrectly. Run any tool with --help.

This is a quality-checking aid. It cannot guarantee that a product is free of defects or
that it meets the rules of any particular marketplace; read those rules yourself.
