feat(cli): add alchemy and improve cli tooling and structure (#520)

This commit is contained in:
Aman Varshney
2025-08-20 23:43:58 +05:30
committed by GitHub
parent c5430ae4fd
commit 5788876c47
152 changed files with 5804 additions and 2264 deletions

View File

@@ -79,6 +79,20 @@ create-better-t-stack my-app --yes --directory-conflict overwrite
create-better-t-stack my-app --yes --directory-conflict increment
```
### `--disable-analytics / --no-disable-analytics`
Control whether analytics and telemetry data is collected.
```bash
# Disable analytics collection
create-better-t-stack --disable-analytics
# Enable analytics collection (default)
create-better-t-stack --no-disable-analytics
```
Analytics help improve Better-T Stack by providing insights into usage patterns. When disabled, no data is collected or transmitted.
## Database Options
### `--database <type>`
@@ -212,6 +226,8 @@ create-better-t-stack --auth
create-better-t-stack --no-auth
```
**Note:** Authentication requires both a database and backend framework to be selected. It is automatically disabled when using Convex backend or when no backend is selected.
## Addons
### `--addons <types...>`
@@ -255,12 +271,31 @@ create-better-t-stack --examples todo ai
Web deployment configuration:
- `none`: No deployment setup
- `workers`: Cloudflare Workers deployment
- `wrangler`: Cloudflare Workers deployment
- `alchemy`: Cloudflare Workers deployment (via Alchemy infrastructure as code)
```bash
create-better-t-stack --web-deploy workers
create-better-t-stack --web-deploy wrangler
create-better-t-stack --web-deploy alchemy
```
**Note:** Alchemy uses TypeScript to define infrastructure programmatically. See the [Infrastructure as Code with Alchemy Guide](/docs/guides/alchemy-deployment) for details.
### `--server-deploy <setup>`
Server deployment configuration:
- `none`: No deployment setup
- `wrangler`: Cloudflare Workers deployment (when runtime is workers)
- `alchemy`: Cloudflare Workers deployment (when runtime is workers, via Alchemy infrastructure as code)
```bash
create-better-t-stack --server-deploy wrangler
create-better-t-stack --server-deploy alchemy
```
**Note:** Alchemy uses TypeScript to define infrastructure programmatically. See the [Infrastructure as Code with Alchemy Guide](/docs/guides/alchemy-deployment) for details.
## Option Validation
The CLI validates option combinations and will show errors for incompatible selections. See the [Compatibility](/docs/cli/compatibility) page for detailed rules.
@@ -281,6 +316,8 @@ create-better-t-stack \
--addons pwa biome \
--examples todo \
--package-manager bun \
--web-deploy wrangler \
--server-deploy alchemy \
--install
```