Skip to main content
Read the headers of the main plugin file and print them as a manifest.

Usage

Arguments

string
required
Path to the main plugin file (e.g. my-plugin/my-plugin.php).

Options

string
Print only the value of one header field (e.g. Name, Version, Author), with no trailing newline, so it can be captured in a variable. With --output=json, the answer is an object: {"<Header>": "value"}, e.g. {"Version":"1.0.0"}.A header that is missing, empty or unknown prints an empty string and exits with 0, as in v1. A notice on stderr says what is missing (silenced by -q; never printed with --output=json).

Examples