[PR #1938] [CLOSED] Expose CLI command as better-auth instead of cli #4080

Closed
opened 2026-03-13 11:31:44 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/1938
Author: @licarth
Created: 3/22/2025
Status: Closed

Base: mainHead: patch-1


📝 Commits (1)

  • 64d5eac Expose CLI command as better-auth instead of cli

📊 Changes

1 file changed (+4 additions, -2 deletions)

View changed files

📝 packages/cli/package.json (+4 -2)

📄 Description

Currently, in my project if I want to use the CLI, I have 2 options :

  1. As docs suggest, run npx @better-auth/cli generate (but not ideal if developing locally on a plane)
  2. Create a script in package.json with this as a command : cli generate

Option 2. should be better-auth generate.

This PR is offering to map better-auth's CLI to better-auth.

⚠️ This is breaking backwards compatibility use of cli in package.json scripts. Even though not documented, some users may do it already.

⚠️ I did not try to build the package and use it in another project.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/better-auth/better-auth/pull/1938 **Author:** [@licarth](https://github.com/licarth) **Created:** 3/22/2025 **Status:** ❌ Closed **Base:** `main` ← **Head:** `patch-1` --- ### 📝 Commits (1) - [`64d5eac`](https://github.com/better-auth/better-auth/commit/64d5eaca26f66b0e7a719d99c8a51fe006eef588) Expose CLI command as `better-auth` instead of `cli` ### 📊 Changes **1 file changed** (+4 additions, -2 deletions) <details> <summary>View changed files</summary> 📝 `packages/cli/package.json` (+4 -2) </details> ### 📄 Description Currently, in my project if I want to use the CLI, I have 2 options : 1. As docs suggest, run `npx @better-auth/cli generate` (but not ideal if developing locally on a plane) 2. Create a script in package.json with this as a command : `cli generate` Option 2. should be `better-auth generate`. This PR is offering to map better-auth's CLI to better-auth. ⚠️ This is breaking backwards compatibility use of `cli` in package.json scripts. Even though not documented, some users may do it already. ⚠️ I did not try to build the package and use it in another project. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-03-13 11:31:44 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#4080