package version displayancestry

Display the ancestry tree for a 2GP managed package version.

force:package:version:displayancestry

Flag Name (Long)Flag Name (Short)Description
‑‑api‑versionN/AType: Value

Override the api version used for api requests made by this command
‑‑dot‑codeN/AType: Boolean

Display the ancestry tree in DOT code.

You can use the DOT code output in graph visualization software to create tree visualizations.
‑‑flags‑dirN/AType: Value

Import flag values from a directory.
‑‑jsonN/AType: Boolean

Format output as json.
‑‑package‑pType: Value
Required

ID or alias of the package (starts with 0Ho) or package version (starts with 04t) to display ancestry for.

If you specify a package ID (starts with 0Ho) or alias, the ancestor tree for every package version associated with the package ID is displayed. If you specify a package version (starts with 04t) or alias, the ancestry tree of the specified package version is displayed.
‑‑target‑dev‑hub‑vType: Value
Required

Username or alias of the Dev Hub org. Not required if the target-dev-hub configuration variable is already set.
‑‑verboseN/AType: Boolean

Display both the package version ID (starts with 04t) and the version number (major.minor.patch.build) in the ancestry tree.

Display the ancestry tree for a package version with the specified alias, using your default Dev Hub org:

Similar to previous example, but display the output in DOT code:

Display the ancestry tree for a package with the specified ID, using the Dev Hub org with username devhub@example.com:

Display the ancestry tree of a package version with the specified ID, using your default Dev Hub org: