mirror of
https://github.com/FranP-code/create-better-t-stack.git
synced 2025-10-12 23:52:15 +00:00
remove biome check after installation
This commit is contained in:
5
.changeset/spicy-lamps-check.md
Normal file
5
.changeset/spicy-lamps-check.md
Normal file
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"create-better-t-stack": patch
|
||||
---
|
||||
|
||||
remove biome check after installation
|
||||
@@ -75,7 +75,6 @@ export async function createProject(options: ProjectConfig) {
|
||||
await installDependencies({
|
||||
projectDir,
|
||||
packageManager: options.packageManager,
|
||||
addons: options.addons,
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { log, spinner } from "@clack/prompts";
|
||||
import { spinner } from "@clack/prompts";
|
||||
import consola from "consola";
|
||||
import { $ } from "execa";
|
||||
import pc from "picocolors";
|
||||
@@ -7,7 +7,6 @@ import type { Addons, PackageManager } from "../../types";
|
||||
export async function installDependencies({
|
||||
projectDir,
|
||||
packageManager,
|
||||
addons = [],
|
||||
}: {
|
||||
projectDir: string;
|
||||
packageManager: PackageManager;
|
||||
@@ -24,10 +23,6 @@ export async function installDependencies({
|
||||
})`${packageManager} install`;
|
||||
|
||||
s.stop("Dependencies installed successfully");
|
||||
|
||||
if (addons.includes("biome") || addons.includes("husky")) {
|
||||
await runBiomeCheck(projectDir, packageManager);
|
||||
}
|
||||
} catch (error) {
|
||||
s.stop(pc.red("Failed to install dependencies"));
|
||||
if (error instanceof Error) {
|
||||
@@ -35,24 +30,3 @@ export async function installDependencies({
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
async function runBiomeCheck(
|
||||
projectDir: string,
|
||||
packageManager: PackageManager,
|
||||
) {
|
||||
const s = spinner();
|
||||
|
||||
try {
|
||||
s.start("Running Biome format check...");
|
||||
|
||||
await $({
|
||||
cwd: projectDir,
|
||||
stderr: "inherit",
|
||||
})`${packageManager} biome check --write .`;
|
||||
|
||||
s.stop("Biome check completed successfully");
|
||||
} catch (_error) {
|
||||
s.stop(pc.yellow("Biome check encountered issues"));
|
||||
log.warn(pc.yellow("Some files may need manual formatting"));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user