Skip to content

oclif/plugin-command-snapshot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

007910c · Jan 11, 2025
Oct 23, 2023
Jun 11, 2024
Jul 23, 2024
Mar 2, 2020
Oct 23, 2023
Oct 23, 2023
May 28, 2024
May 22, 2024
Oct 23, 2023
Mar 2, 2020
Oct 23, 2023
Apr 9, 2024
Feb 22, 2024
Oct 23, 2023
Oct 23, 2023
Jan 11, 2025
Mar 18, 2024
Mar 2, 2020
Mar 24, 2024
May 15, 2023
Jan 11, 2025
Feb 22, 2024
Jan 11, 2025

Repository files navigation

@oclif/plugin-command-snapshot

Generates and compares OCLIF plugins snapshot files

oclif Version Downloads/week License

Usage

This plugin is used to take snapshot of commands and flags in OCLIF plugins. These snapshots can be used to enforce a deprecation policy or to keep track of changes.

To include it in your plugin, add it to the devPlugins section in your package.json.

"oclif": {
    ...
    "devPlugins": [
      "@oclif/plugin-command-snapshot"
      ...
    ]

Use the snapshot:generate command in your development process.

# generates a snapshot file that has a list or commands and flags in the current CLI or plugin
$ ./bin/run.js snapshot:generate

Use the snapshot:compare command in your continuos integration. This command will fail if changes are detected. The snapshot file should be updated and committed to the repository when legitimate changes are made.

# compare the current CLI or plugin commands and flags with a snapshot file to identify changes
$ ./bin/run.js snapshot:compare

Contributing

See contributing guide