Workflow: sparse partial checkout (code and _incoming only), book lookup before processing, safe rebase retry; revert cancel-in-progress

This commit is contained in:
Audiobook Producer
2026-10-18 01:48:48 -05:00
parent 517e76c533
commit 153153010e
6 changed files with 77 additions and 18 deletions
+10
View File
@@ -71,6 +71,8 @@ def main(argv=None):
p.add_argument("--compare", help="a books folder (like the repo books/); the text-stage output is compared with the same <author>/<book> folder in it")
p.add_argument("--compare-strict", action="store_true", help="with --compare: fail when the output differs (default: report only)")
p.add_argument("--result-file", help="write {ok, book_dir, pdf} JSON here")
p = sub.add_parser("bookpath", help="print the book folder (relative to the repo root) this PDF will go to")
p.add_argument("pdf")
p = sub.add_parser("ingest")
p.add_argument("pdf")
p.add_argument("--title")
@@ -92,6 +94,14 @@ def main(argv=None):
a = ap.parse_args(argv)
cfg = settings.load(a.settings)
if a.cmd == "bookpath":
import process
try:
title, author, _ = process.resolve_meta(os.path.abspath(a.pdf))
except process.Failed as e:
sys.exit(str(e))
print(os.path.relpath(ingest.book_folder(cfg, author, title), settings.REPO_ROOT))
return
if a.cmd == "process":
import process
sys.exit(process.process(cfg, a.pdf, a.dry_run, a.force, a.title, a.author, a.compare, a.result_file, a.compare_strict))