chore: migrate to auto for versioning

This commit is contained in:
Aman Varshney
2025-08-15 13:43:45 +05:30
parent 8818924fae
commit a632f76948
8 changed files with 1876 additions and 272 deletions

28
.autorc Normal file
View File

@@ -0,0 +1,28 @@
{
"plugins": [
[
"npm",
{
"forcePublish": false,
"subPackageChangelogs": true
}
],
"all-contributors",
"conventional-commits",
"first-time-contributor",
"released"
],
"author": "Aman Varshney <amanvarshney.work@gmail.com>",
"repo": "AmanVarshney01/create-better-t-stack",
"name": "Aman Varshney",
"email": "amanvarshney.work@gmail.com",
"baseBranch": "main",
"labels": [
{
"name": "skip-release",
"changelogTitle": "⚠️ Pushed to `main`",
"description": "Skip a release and only update the changelog",
"releaseType": "skip"
}
]
}

View File

@@ -1,8 +0,0 @@
# Changesets
Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
with multi-package repos, or single-package repos to help you version and publish your code. You can
find the full documentation for it [in our repository](https://github.com/changesets/changesets)
We have a quick list of common questions to get you started engaging with this project in
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)

View File

@@ -1,11 +0,0 @@
{
"$schema": "https://unpkg.com/@changesets/config@3.0.5/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "public",
"baseBranch": "main",
"updateInternalDependencies": "patch",
"ignore": ["@better-t-stack/backend", "web"]
}

View File

@@ -4,23 +4,18 @@ on:
push: push:
branches: branches:
- main - main
- beta pull_request:
paths:
- "apps/cli/**"
- ".changeset/**"
- "package.json"
- "bun.lock"
concurrency: ${{ github.workflow }}-${{ github.ref }}
jobs: jobs:
release: release:
runs-on: ubuntu-latest runs-on: ubuntu-latest
if: "!contains(github.event.head_commit.message, 'ci skip') && !contains(github.event.head_commit.message, 'skip ci')"
steps: steps:
- name: Checkout Code - name: Checkout Code
uses: actions/checkout@v4 uses: actions/checkout@v4
with:
fetch-depth: 0 - name: Prepare repository
run: git fetch --unshallow --tags
- name: Setup Bun - name: Setup Bun
uses: oven-sh/setup-bun@v2 uses: oven-sh/setup-bun@v2
@@ -30,14 +25,14 @@ jobs:
- name: Install Dependencies - name: Install Dependencies
run: bun install --frozen-lockfile run: bun install --frozen-lockfile
- name: Create Release Pull Request or Publish - name: Build CLI
id: changesets run: bun run build:cli
uses: changesets/action@v1
with: - name: Create Release
publish: bun run publish-packages
env: env:
BTS_TELEMETRY: 1
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
BTS_TELEMETRY: 1
POSTHOG_API_KEY: ${{ secrets.POSTHOG_API_KEY }} POSTHOG_API_KEY: ${{ secrets.POSTHOG_API_KEY }}
POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }} POSTHOG_HOST: ${{ secrets.POSTHOG_HOST }}
run: bun auto shipit

View File

@@ -43,6 +43,9 @@
"url": "git+https://github.com/AmanVarshney01/create-better-t-stack.git", "url": "git+https://github.com/AmanVarshney01/create-better-t-stack.git",
"directory": "apps/cli" "directory": "apps/cli"
}, },
"publishConfig": {
"access": "public"
},
"homepage": "https://better-t-stack.dev/", "homepage": "https://better-t-stack.dev/",
"scripts": { "scripts": {
"build": "tsdown", "build": "tsdown",
@@ -50,8 +53,7 @@
"check-types": "tsc --noEmit", "check-types": "tsc --noEmit",
"check": "biome check --write .", "check": "biome check --write .",
"test": "bun run build && vitest --ui", "test": "bun run build && vitest --ui",
"test:with-build": "bun run build && WITH_BUILD=1 vitest --ui", "test:with-build": "bun run build && WITH_BUILD=1 vitest --ui"
"prepublishOnly": "npm run build"
}, },
"exports": { "exports": {
".": { ".": {

1957
bun.lock

File diff suppressed because it is too large Load Diff

19
lerna.json Normal file
View File

@@ -0,0 +1,19 @@
{
"version": "2.33.4",
"npmClient": "bun",
"command": {
"publish": {
"conventionalCommits": true,
"message": "chore(release): publish",
"verifyAccess": false
},
"version": {
"conventionalCommits": true,
"message": "chore(release): version"
}
},
"packages": [
"apps/*",
"packages/*"
]
}

View File

@@ -1,42 +1,54 @@
{ {
"name": "better-t-stack", "name": "better-t-stack",
"private": true, "version": "2.33.4",
"scripts": { "private": true,
"build": "turbo build", "scripts": {
"dev": "turbo dev", "build": "turbo build",
"dev:cli": "turbo run dev --filter=create-better-t-stack", "dev": "turbo dev",
"cli": "cd apps/cli && node dist/cli.js", "dev:cli": "turbo run dev --filter=create-better-t-stack",
"dev:web": "turbo run dev --filter=web", "cli": "cd apps/cli && node dist/cli.js",
"build:web": "turbo run build --filter=web", "dev:web": "turbo run dev --filter=web",
"build:cli": "turbo run build --filter=create-better-t-stack", "build:web": "turbo run build --filter=web",
"lint": "turbo lint", "build:cli": "turbo run build --filter=create-better-t-stack",
"check": "turbo check", "lint": "turbo lint",
"format": "biome check --write .", "check": "turbo check",
"publish-packages": "turbo run build --filter=create-better-t-stack && changeset publish", "format": "biome check --write .",
"deploy:convex": "turbo run --filter=@better-t-stack/backend deploy", "deploy:convex": "turbo run --filter=@better-t-stack/backend deploy",
"deploy:web": "bun run --filter=web deploy", "deploy:web": "bun run --filter=web deploy",
"generate": "bun run --filter=web generate-analytics && bun run --filter=web generate-schema", "generate": "bun run --filter=web generate-analytics && bun run --filter=web generate-schema",
"deploy": "bun run deploy:web" "deploy": "bun run deploy:web",
}, "release": "auto shipit",
"devDependencies": { "version": "auto version",
"@biomejs/biome": "2.1.2", "changelog": "auto changelog",
"@changesets/cli": "^2.29.5", "publish": "auto shipit --dry-run"
"husky": "^9.1.7", },
"lint-staged": "^16.1.2", "devDependencies": {
"turbo": "^2.5.5", "@auto-it/all-contributors": "^11.3.0",
"typescript": "5.8.3" "@auto-it/conventional-commits": "^11.3.0",
}, "@auto-it/first-time-contributor": "^11.3.0",
"lint-staged": { "@auto-it/released": "^11.3.0",
"*": [ "@biomejs/biome": "2.1.2",
"bun biome check --write ." "auto": "^11.3.0",
] "husky": "^9.1.7",
}, "lerna": "^8.2.3",
"engines": { "lint-staged": "^16.1.2",
"node": ">=20" "turbo": "^2.5.5",
}, "typescript": "5.8.3"
"packageManager": "bun@1.2.19", },
"workspaces": [ "lint-staged": {
"apps/*", "*": [
"packages/*" "bun biome check --write ."
] ]
},
"engines": {
"node": ">=20"
},
"packageManager": "bun@1.2.20",
"workspaces": [
"apps/*",
"packages/*"
],
"repository": "AmanVarshney01/create-better-t-stack",
"author": "Aman Varshney <amanvarshney.work@gmail.com>",
"dependencies": {}
} }