Skip to content

fix: install @better-auth/cli as a dev dependency#950

Merged
jycouet merged 10 commits intosveltejs:mainfrom
sacrosanctic:widespread-magpie
Feb 28, 2026
Merged

fix: install @better-auth/cli as a dev dependency#950
jycouet merged 10 commits intosveltejs:mainfrom
sacrosanctic:widespread-magpie

Conversation

@sacrosanctic
Copy link
Contributor

@sacrosanctic sacrosanctic commented Feb 27, 2026

closes #937

in this pr:

  • remove reliance on a package manager by installing the cli as a dev dependency
  • update pnpm install instructions to use corepack (src / src)
  • use pnpm dlx (src)
  • lock create and add args to a specific version for reproducibility

@svelte-docs-bot
Copy link

@changeset-bot
Copy link

changeset-bot bot commented Feb 27, 2026

🦋 Changeset detected

Latest commit: d5d7c93

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
sv Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new
Copy link

pkg-pr-new bot commented Feb 27, 2026

Open in StackBlitz

npx https://pkg.pr.new/svelte-migrate@950
npx https://pkg.pr.new/sv@950
npx https://pkg.pr.new/@sveltejs/sv-utils@950

commit: b88bcc5

@paoloricciuti
Copy link
Member

An even better way could be to add @better-auth/cli as a dev dependency and have the command be better-auth generate --config src/lib/server/auth.ts --output src/lib/server/db/auth.schema.ts --yes...just tested and it works (and I prefer that to always install)

@sacrosanctic sacrosanctic changed the title fix: use adaptive package manager in scripts fix: install @bettter-auth/cli as a dev dependency Feb 27, 2026
@sacrosanctic sacrosanctic marked this pull request as ready for review February 27, 2026 11:22
@sacrosanctic sacrosanctic changed the title fix: install @bettter-auth/cli as a dev dependency fix: install @better-auth/cli as a dev dependency Feb 27, 2026
Co-authored-by: Antoine Lethimonnier <43064022+WarningImHack3r@users.noreply.github.com>
lastArgs: string[] = []
): string {
const allArgs = ['sv', command, ...args];
const allArgs = [`sv@${pkg.version}`, command, ...args];
Copy link
Contributor

Choose a reason for hiding this comment

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

Hummm, not sure why we do this in this PR?
There is a specific need for it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Was just tapping away and ended up grouping a few things together. I think its necessary for reproducibility.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ok, let's keep it in 👍

Copy link
Contributor

@jycouet jycouet left a comment

Choose a reason for hiding this comment

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

@jycouet jycouet merged commit 5faf989 into sveltejs:main Feb 28, 2026
7 checks passed
@github-actions github-actions bot mentioned this pull request Feb 28, 2026
@sacrosanctic sacrosanctic deleted the widespread-magpie branch February 28, 2026 15:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Better-Auth] Use the selected package manager for the auth:schema script

4 participants