Skip to content

CLI: Silence automigrations and skip doctor checks in post install #31589

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
May 28, 2025

Conversation

yannbf
Copy link
Member

@yannbf yannbf commented May 28, 2025

Closes #

What I did

Checklist for Contributors

Testing

The changes in this PR are covered in the following automated tests:

  • stories
  • unit tests
  • integration tests
  • end-to-end tests

Manual testing

This section is mandatory for all contributions. If you believe no manual test is necessary, please state so explicitly. Thanks!

Documentation

  • Add or update documentation reflecting your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Checklist for Maintainers

  • When this PR is ready for testing, make sure to add ci:normal, ci:merged or ci:daily GH label to it to run a specific set of sandboxes. The particular set of sandboxes can be found in code/lib/cli-storybook/src/sandbox-templates.ts

  • Make sure this PR contains one of the labels below:

    Available labels
    • bug: Internal changes that fixes incorrect behavior.
    • maintenance: User-facing maintenance tasks.
    • dependencies: Upgrading (sometimes downgrading) dependencies.
    • build: Internal-facing build tooling & test updates. Will not show up in release changelog.
    • cleanup: Minor cleanup style change. Will not show up in release changelog.
    • documentation: Documentation only changes. Will not show up in release changelog.
    • feature request: Introducing a new feature.
    • BREAKING CHANGE: Changes that break compatibility in some way with current major version.
    • other: Changes that don't fit in the above categories.

🦋 Canary release

This pull request has been released as version 0.0.0-pr-31589-sha-71707764. Try it out in a new sandbox by running npx [email protected] sandbox or in an existing project with npx [email protected] upgrade.

More information
Published version 0.0.0-pr-31589-sha-71707764
Triggered by @yannbf
Repository storybookjs/storybook
Branch yann/silence-postinstall-steps
Commit 71707764
Datetime Wed May 28 09:51:05 UTC 2025 (1748425865)
Workflow run 15297071416

To request a new release of this pull request, mention the @storybookjs/core team.

core team members can create a new canary release here or locally with gh workflow run --repo storybookjs/storybook canary-release-pr.yml --field pr=31589

Greptile Summary

This PR adds options to silence automigrations and skip doctor checks during post-installation across Storybook's CLI and addons, streamlining the installation process by reducing verbose output and optional checks.

  • Added silent and skipDoctor options to AutofixOptionsFromCLI interface in code/lib/cli-storybook/src/automigrate/types.ts
  • Modified code/lib/cli-storybook/src/bin/index.ts to support new --silent and --skip-doctor CLI flags
  • Updated postinstall scripts in code/addons/a11y/src/postinstall.ts and code/addons/vitest/src/postinstall.ts to use new silent flags
  • Added conditional logging in code/lib/cli-storybook/src/automigrate/index.ts to respect silent mode

@yannbf yannbf self-assigned this May 28, 2025
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

6 file(s) reviewed, 1 comment(s)
Edit PR Review Bot Settings | Greptile

Comment on lines 207 to 219
.option('--silent', 'Silent mode')
.option('--skip-doctor', 'Skip doctor check')
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style: consider adding descriptions for these options to match style of other options

Copy link

nx-cloud bot commented May 28, 2025

View your CI Pipeline Execution ↗ for commit 17d7065.

Command Status Duration Result
nx run-many -t build --parallel=3 ✅ Succeeded 1m 25s View ↗

☁️ Nx Cloud last updated this comment at 2025-05-28 17:49:51 UTC

@storybook-pr-benchmarking
Copy link

storybook-pr-benchmarking bot commented May 28, 2025

Package Benchmarks

Commit: 17d7065, ran on 28 May 2025 at 17:52:02 UTC

The following packages have significant changes to their size or dependencies:

@storybook/addon-vitest

Before After Difference
Dependency count 6 6 0
Self size 629 KB 552 KB 🎉 -77 KB 🎉
Dependency size 1.49 MB 1.49 MB 0 B
Bundle Size Analyzer Link Link

@yannbf yannbf force-pushed the yann/silence-postinstall-steps branch from 7170776 to 3c1c790 Compare May 28, 2025 13:37
@yannbf yannbf force-pushed the yann/silence-postinstall-steps branch from 614882f to d3eb4c7 Compare May 28, 2025 13:45
@yannbf yannbf force-pushed the yann/silence-postinstall-steps branch from d3eb4c7 to 308ce03 Compare May 28, 2025 14:05
@yannbf yannbf merged commit aecf389 into valentin/monorepo-enhancements May 28, 2025
53 of 55 checks passed
@yannbf yannbf deleted the yann/silence-postinstall-steps branch May 28, 2025 19:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant