Skip to content

Commit 3968c40

Browse files
jasencarrollclaude
andcommitted
fix CI: migrate biome config to 2.4.6, disable biome formatter (use Prettier), bump min bun to 1.2.0
- Ran `biome migrate` to update schema from 2.0.6 to 2.4.6 - Disabled biome formatter to avoid conflicts with Prettier - Disabled noUnknownAtRules (Tailwind @Directives), noDuplicateProperties, noFallthroughSwitchClause, noNonNullAssertion - Excluded HTML templates and generated CSS from biome checks - Bumped CI test matrix min bun version from 1.0.0 to 1.2.0 for lockfile compatibility - Auto-fixed organize imports and formatting issues Co-Authored-By: Claude Opus 4.6 <[email protected]>
1 parent 7f720c1 commit 3968c40

File tree

26 files changed

+278
-168
lines changed

26 files changed

+278
-168
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
strategy:
2727
matrix:
2828
os: [ubuntu-latest, macos-latest]
29-
bun-version: [latest, "1.1.0"]
29+
bun-version: [latest, "1.2.0"]
3030
steps:
3131
- uses: actions/checkout@v4
3232
- uses: oven-sh/setup-bun@v2

biome.json

Lines changed: 26 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,20 @@
11
{
2-
"$schema": "https://biomejs.dev/schemas/2.0.6/schema.json",
2+
"$schema": "https://biomejs.dev/schemas/2.4.6/schema.json",
33
"linter": {
44
"enabled": true,
55
"rules": {
6-
"recommended": true
6+
"recommended": true,
7+
"suspicious": {
8+
"noFallthroughSwitchClause": "off",
9+
"noUnknownAtRules": "off"
10+
},
11+
"style": {
12+
"noNonNullAssertion": "off"
13+
}
714
}
815
},
916
"formatter": {
10-
"enabled": true,
11-
"formatWithErrors": false,
12-
"indentStyle": "space",
13-
"indentWidth": 2,
14-
"lineWidth": 100,
15-
"lineEnding": "lf"
17+
"enabled": false
1618
},
1719
"javascript": {
1820
"formatter": {
@@ -22,16 +24,22 @@
2224
}
2325
},
2426
"files": {
25-
"include": ["**/*.js", "**/*.jsx", "**/*.ts", "**/*.tsx", "**/*.json"],
26-
"ignore": [
27-
"node_modules",
28-
".create-bun-stack",
29-
"*.lock",
30-
"dist",
31-
"build",
32-
"test-output",
33-
"templates/default/node_modules",
34-
"public/main.js"
27+
"includes": [
28+
"**/*.js",
29+
"**/*.jsx",
30+
"**/*.ts",
31+
"**/*.tsx",
32+
"**/*.json",
33+
"!**/node_modules",
34+
"!**/.create-bun-stack",
35+
"!**/*.lock",
36+
"!**/dist",
37+
"!**/build",
38+
"!**/test-output",
39+
"!**/templates/default/node_modules",
40+
"!**/public/main.js",
41+
"!**/templates/**/*.html",
42+
"!**/templates/**/public/styles.css"
3543
],
3644
"maxSize": 2097152
3745
}

cli.ts

Lines changed: 52 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,15 @@ export function validateProjectName(name: string): string | null {
9696
}
9797
}
9898

99-
const reservedNames = ["node_modules", "test", "tests", "src", "dist", "build", "public"];
99+
const reservedNames = [
100+
"node_modules",
101+
"test",
102+
"tests",
103+
"src",
104+
"dist",
105+
"build",
106+
"public",
107+
];
100108
if (reservedNames.includes(name.toLowerCase())) {
101109
return `"${name}" is a reserved name. Please choose a different name.`;
102110
}
@@ -109,7 +117,9 @@ async function main() {
109117
const isNonInteractive = cliOptions.name !== undefined;
110118

111119
// Only create readline for interactive mode
112-
const rl = isNonInteractive ? null : readline.createInterface({ input, output });
120+
const rl = isNonInteractive
121+
? null
122+
: readline.createInterface({ input, output });
113123

114124
if (!cliOptions.quiet) {
115125
console.log(`
@@ -172,9 +182,13 @@ async function main() {
172182
if (code === "EEXIST") {
173183
console.error(`❌ Directory ${projectName} already exists`);
174184
} else if (code === "EACCES" || code === "EPERM") {
175-
console.error(`❌ Permission denied: cannot create directory ${projectName}`);
185+
console.error(
186+
`❌ Permission denied: cannot create directory ${projectName}`,
187+
);
176188
} else {
177-
console.error(`❌ Failed to create directory: ${(err as Error).message}`);
189+
console.error(
190+
`❌ Failed to create directory: ${(err as Error).message}`,
191+
);
178192
}
179193
process.exit(1);
180194
}
@@ -227,7 +241,8 @@ To use PostgreSQL:
227241
break;
228242
case "sqlite":
229243
dbProvider = "sqlite";
230-
dbInstructions = "\nSQLite will be used (no additional setup required).";
244+
dbInstructions =
245+
"\nSQLite will be used (no additional setup required).";
231246
break;
232247
default:
233248
dbProvider = "auto";
@@ -243,7 +258,9 @@ To use PostgreSQL:
243258
console.log("2. SQLite (perfect for development)");
244259
console.log("3. Auto-detect (PostgreSQL with SQLite fallback)");
245260

246-
const dbChoice = (await rl!.question("\nChoose database option (1-3) [default: 3]: ")) || "3";
261+
const dbChoice =
262+
(await rl!.question("\nChoose database option (1-3) [default: 3]: ")) ||
263+
"3";
247264

248265
switch (dbChoice) {
249266
case "1":
@@ -258,7 +275,8 @@ To use PostgreSQL:
258275
break;
259276
case "2":
260277
dbProvider = "sqlite";
261-
dbInstructions = "\nSQLite will be used (no additional setup required).";
278+
dbInstructions =
279+
"\nSQLite will be used (no additional setup required).";
262280
break;
263281
default:
264282
dbProvider = "auto";
@@ -275,7 +293,9 @@ To use PostgreSQL:
275293
const templateDir = join(import.meta.dir, "templates", "default");
276294

277295
if (!existsSync(templateDir)) {
278-
console.error("❌ Template directory not found. Your create-bun-stack installation may be corrupted.");
296+
console.error(
297+
"❌ Template directory not found. Your create-bun-stack installation may be corrupted.",
298+
);
279299
console.error(" Try reinstalling: bun install -g create-bun-stack");
280300
process.exit(1);
281301
}
@@ -284,7 +304,12 @@ To use PostgreSQL:
284304
dbProvider: dbProvider,
285305
};
286306

287-
await copyTemplateDirectory(templateDir, projectPath, templateVariables, getExcludePatterns());
307+
await copyTemplateDirectory(
308+
templateDir,
309+
projectPath,
310+
templateVariables,
311+
getExcludePatterns(),
312+
);
288313
if (!cliOptions.quiet) {
289314
console.log("✅ Project structure created");
290315
}
@@ -335,7 +360,9 @@ dist/
335360
// Prompt for git init
336361
let shouldInitGit = false;
337362
if (!isNonInteractive) {
338-
const gitInitAnswer = await rl!.question("\n🐙 Initialize git repository? (Y/n): ");
363+
const gitInitAnswer = await rl!.question(
364+
"\n🐙 Initialize git repository? (Y/n): ",
365+
);
339366
shouldInitGit = gitInitAnswer.toLowerCase() !== "n";
340367
}
341368

@@ -388,7 +415,9 @@ dist/
388415
chmodSync(envPath, 0o600); // Owner read/write only — .env contains secrets
389416
} catch {
390417
if (!cliOptions.quiet) {
391-
console.log("⚠️ Could not copy .env.example to .env - you can do this manually");
418+
console.log(
419+
"⚠️ Could not copy .env.example to .env - you can do this manually",
420+
);
392421
}
393422
}
394423
}
@@ -399,7 +428,9 @@ dist/
399428
if (isNonInteractive) {
400429
shouldSetupDb = true;
401430
} else {
402-
const dbSetupAnswer = await rl!.question("\n🗄️ Setup database now? (Y/n): ");
431+
const dbSetupAnswer = await rl!.question(
432+
"\n🗄️ Setup database now? (Y/n): ",
433+
);
403434
shouldSetupDb = dbSetupAnswer.toLowerCase() !== "n";
404435
}
405436
}
@@ -421,7 +452,9 @@ dist/
421452

422453
// Offer to seed (skip in non-interactive mode)
423454
if (!isNonInteractive) {
424-
const shouldSeed = await rl!.question("\n🌱 Seed database with sample data? (y/N): ");
455+
const shouldSeed = await rl!.question(
456+
"\n🌱 Seed database with sample data? (y/N): ",
457+
);
425458
if (shouldSeed.toLowerCase() === "y") {
426459
const seedProc = Bun.spawn(["bun", "run", "db:seed"], {
427460
stdout: cliOptions.quiet ? "ignore" : "inherit",
@@ -436,7 +469,9 @@ dist/
436469
}
437470
} else {
438471
if (!cliOptions.quiet) {
439-
console.log("⚠️ Database setup failed - you can run 'bun run db:push' later");
472+
console.log(
473+
"⚠️ Database setup failed - you can run 'bun run db:push' later",
474+
);
440475
}
441476
}
442477
}
@@ -457,7 +492,9 @@ dist/
457492
}
458493
} else {
459494
if (!cliOptions.quiet) {
460-
console.log("⚠️ CSS build failed - you can run 'bun run build:css' later");
495+
console.log(
496+
"⚠️ CSS build failed - you can run 'bun run build:css' later",
497+
);
461498
}
462499
}
463500

templates/default/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,12 +108,12 @@ This project includes Railway deployment configuration:
108108
- Show the URL in the deployment logs and settings
109109

110110
**Finding your URL:**
111+
111112
- Go to your service's Settings tab in Railway
112113
- Look for the "Domains" section
113114
- Click "Generate Domain" if not already created
114115
- Your app will be available at the generated URL
115116

116-
117117
### Docker
118118

119119
Build and run locally:
@@ -132,13 +132,13 @@ Bun Stack is more than a fullstack starter — it's everything you'd build if yo
132132
- ✅ Auth, routing, DB, CI/CD
133133
- ✅ Docker + 1-click Railway deploy
134134
- ✅ Convention-driven structure
135-
No yak shaving. No config hell. No architecture debates.
135+
No yak shaving. No config hell. No architecture debates.
136136

137137
Just code. Just ship.
138138

139139
---
140140

141-
### Built by [Jasen](https://jasenc.dev)
141+
### Built by [Jasen](https://jasenc.dev)
142142

143143
Engineer. Systems thinker. MBA. ADHD-fueled DX evangelist.
144144
I built Bun Stack to democratize the leverage that took me 15 years to earn.

templates/default/biome.json

Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,19 @@
11
{
2-
"$schema": "https://biomejs.dev/schemas/1.8.3/schema.json",
3-
"organizeImports": {
4-
"enabled": true
5-
},
2+
"root": false,
3+
"$schema": "https://biomejs.dev/schemas/2.4.6/schema.json",
4+
"assist": { "actions": { "source": { "organizeImports": "on" } } },
65
"linter": {
76
"enabled": true,
87
"rules": {
9-
"recommended": true
8+
"recommended": true,
9+
"suspicious": {
10+
"noUnknownAtRules": "off",
11+
"noDuplicateProperties": "off"
12+
}
1013
}
1114
},
1215
"formatter": {
13-
"enabled": true,
14-
"formatWithErrors": false,
15-
"indentStyle": "space",
16-
"indentWidth": 2,
17-
"lineWidth": 100,
18-
"lineEnding": "lf"
16+
"enabled": false
1917
},
2018
"javascript": {
2119
"formatter": {
@@ -25,14 +23,17 @@
2523
}
2624
},
2725
"files": {
28-
"ignore": [
29-
"node_modules",
30-
".create-bun-stack",
31-
"*.lock",
32-
"dist",
33-
"build",
34-
"test-output",
35-
"public/main.js"
26+
"includes": [
27+
"**",
28+
"!**/node_modules",
29+
"!**/.create-bun-stack",
30+
"!**/*.lock",
31+
"!**/dist",
32+
"!**/build",
33+
"!**/test-output",
34+
"!**/public/main.js",
35+
"!**/*.html",
36+
"!**/public/styles.css"
3637
],
3738
"maxSize": 2097152
3839
}

0 commit comments

Comments
 (0)