Skip to content

Conversation

@devin-ai-integration
Copy link
Contributor

@devin-ai-integration devin-ai-integration bot commented Dec 23, 2025

Description

Refs: Slack request from Catherine

When users run fern docs preview without a subcommand, they now receive a clear error message explaining that this is not a valid command and suggesting they use fern generate --docs --preview instead.

Link to Devin run: https://app.devin.ai/sessions/6143cdc4694e4ed4a7f10b7842a1d805
Requested by: Catherine Deskur (catherine@buildwithfern.com)

Changes Made

  • Added a default command handler ($0) to the fern docs preview command that displays an error message when no subcommand is provided
  • Error message: 'fern docs preview' is not a valid command. To preview docs, use 'fern generate --docs --preview'.
  • Added changelog entry for version 3.31.1

Testing

  • Lint checks pass (pnpm run check)
  • Manual testing of CLI command completed locally

Tested with FERN_NO_VERSION_REDIRECTION=true to bypass version redirection:

$ FERN_NO_VERSION_REDIRECTION=true node packages/cli/cli/dist/prod/cli.cjs docs preview
'fern docs preview' is not a valid command. To preview docs, use 'fern generate --docs --preview'.

Human Review Checklist

  • Verify the error message wording is clear and helpful
  • Confirm this behavior (error + fail) is preferred over showing help text
Co-Authored-By: Catherine Deskur <catherine@buildwithfern.com>
@devin-ai-integration
Copy link
Contributor Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring
Co-Authored-By: Catherine Deskur <catherine@buildwithfern.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant