storyblok / field-plugin

Create and deploy Storyblok Field Plugin
https://www.storyblok.com/docs/plugins/field-plugins/introduction
25 stars 3 forks source link

Extend CLI with --publish flag option configurable #380

Open edvinasjurele opened 3 months ago

edvinasjurele commented 3 months ago

Is your feature request related to a problem? Please describe.

As we see the publish: true is enabled in CLI (https://github.com/storyblok/field-plugin/blob/main/packages/cli/src/commands/deploy/helper.ts#L83C7-L83C21), this it is not possible to push an update of the Plugin in draft level, thus it gets instantly published, which may not align with the way teams may use it in CI automations.

Describe the solution you'd like

It should be possible to define --publish false (though by default it is enabled, that is fine), so the release process would be 2 steps:

  1. CI automation pushes new version of plugin after monorepo project tag creation in "draft" level
  2. Release manager or QA makes sure the plugin is as expected
  3. Manually publish a certain version to go live.

Describe alternatives you've considered

No alternatives, we have to be sure the version we push is the one we want to appear on production, thus there is no doublecheck step or other flows possible.

Additional context

Severity: minor.