Skip to content

Feature request: Machine-readable CLI output #583

Open
@stevenpetryk

Description

@stevenpetryk

Would be great to have a --json flag, or something similar. As it stands, if one wants to integrate Oxipng into another CLI tool (like I'm trying to do at my company), it's not really possible to easily parse the CLI output and figure out what images were optimized vs skipped.

Example output might be something like:

{
  "result": "success",
  "images": [
    { "path": "/path/to/image.png",
      "original_size": 13232,
      "optimized_size": 11323,
    },
    // ...
  ]
}

Could pipe more and more into these objects over time (like timing data, or what optimizations were applied, etc.)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-FeatureRequests for a new feature to be added

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions