Skip to content
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

CLI: Multiple Registries #4950

Open
wants to merge 19 commits into
base: main
Choose a base branch
from
Open

CLI: Multiple Registries #4950

wants to merge 19 commits into from

Conversation

zbeyens
Copy link

@zbeyens zbeyens commented Sep 24, 2024

This update adds support for multiple registries in components.json.

  • See cli.mdx and changelog.mdx for details.
  • I've added a minimal registry config at packages/shadcn/test/fixtures/next/public/r. This should be documented at some point.
  • While not unit tested, I've added a few scripts for manual testing:
    • pnpm install --ignore-workspace in packages/shadcn/test/fixtures/next
    • dev:r1 to start the r1 app
    • init:r0 to initialize the default registry
    • init:r1 to initialize the r1 registry. You can try to run init:r0 then init:r1, or the opposite.
    • init:r2 to initialize the r2 registry
    • add:r0 to add a default component
    • add:r1 to add a component from the r1 registry
  • Additionally, the init command will now fetch the registry's config.json as the default configuration to use. It falls back to the shadcn default config if not found.

Feel free to refactor with your own style.

Copy link

vercel bot commented Sep 24, 2024

@zbeyens is attempting to deploy a commit to the shadcn-pro Team on Vercel.

A member of the Team first needs to authorize it.

@zbeyens zbeyens marked this pull request as ready for review September 24, 2024 01:53
@shadcn
Copy link
Collaborator

shadcn commented Sep 27, 2024

@zbeyens Just a quick update. I'm considering this and will review. Working on an rfc before we introduce this. Thanks for the PR. It looks great.

@shadcn shadcn added area: roadmap This looks great. We'll add it to the roadmap, review and merge. area: shadcn labels Sep 27, 2024
@shadcn shadcn self-assigned this Sep 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: roadmap This looks great. We'll add it to the roadmap, review and merge. area: shadcn
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants