Skip to content

Add pdfbaker validate #14

@dannyadair

Description

@dannyadair

Takes config file argument like bake.
Performs a quick validation to confirm that all requirements are met:

  • config found
  • config syntactically valid
  • config has required keys (documents)
  • directories of documents (as listed) exist
  • document configs found
  • document configs syntactically valid
  • document configs have required keys (filename, pages) - should "filename" maybe be changed to "name"?
  • pages found as configured (directory, config)
  • page configs syntactically valid
  • page config has required keys (name) - should "name" maybe be changed to "filename"?
  • if images are listed, images exist (going too far?)
  • templates found as configured
  • validate template content? (defusedxml check well formed, root is ) (going too far?)
  • Inkscape installed if required by config
  • Ghostscript installed if required by config
  • build directory/directories already exist (warning)
  • dist directory/directories already exist (warning)

Put this in a separate module.
Always run this first before attempting bake. (still good for the user to have this separate command)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions