From 56dd8c24165e327e5b6f77307e2dbf263318a37c Mon Sep 17 00:00:00 2001 From: Agustinus Nathaniel Date: Mon, 16 Sep 2024 14:46:22 +0700 Subject: [PATCH] chore: update scripts --- biome.json | 4 ++++ package.json | 10 +++++----- turbo.json | 16 +++++++++------- 3 files changed, 18 insertions(+), 12 deletions(-) diff --git a/biome.json b/biome.json index 0a29d694..92da2016 100644 --- a/biome.json +++ b/biome.json @@ -3,6 +3,10 @@ "organizeImports": { "enabled": true }, + "files": { + "include": ["src", "*.config.ts"], + "ignore": [".next", "node_modules", ".turbo", ".vscode"] + }, "formatter": { "indentStyle": "space" }, diff --git a/package.json b/package.json index 27a85e42..43916626 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,8 @@ "turbo": "pnpm dlx turbo@2.0.9", "build:turbo": "pnpm turbo build", "lint:next": "next lint", - "lint:biome": "pnpm biome lint ./src", + "biome:check": "pnpm biome lint", + "biome:apply": "pnpm biome:check --write", "analyze": "cross-env ANALYZE=true pnpm build", "postbuild": "next-sitemap --config next-sitemap.config.js", "test": "vitest", @@ -20,11 +21,10 @@ "test:run": "vitest run", "test:coverage": "vitest --coverage", "start": "next start", - "lint": "pnpm lint:next && pnpm lint:biome", - "biome:apply": "pnpm biome check --write ./src next.config.js commitlint.*", - "type-check": "tsc --noEmit", + "lint": "pnpm lint:next && pnpm biome:check", + "type:check": "tsc --noEmit", "knip": "knip", - "check:turbo": "pnpm turbo lint type-check", + "check:turbo": "pnpm turbo biome:check type:check", "up-interactive": "pnpm up -i", "up-latest": "pnpm up-interactive -L", "release": "cross-env HUSKY=0 standard-version", diff --git a/turbo.json b/turbo.json index 7c8eb9cd..0f598cff 100644 --- a/turbo.json +++ b/turbo.json @@ -1,7 +1,16 @@ { "$schema": "https://turbo.build/schema.json", "tasks": { + "biome:check": { + "outputs": [], + "inputs": ["biome.json", "src/**"] + }, + "type:check": { + "inputs": ["tsconfig.json", "src/**"], + "outputs": ["*.tsbuildinfo"] + }, "build": { + "dependsOn": ["type:check", "biome:check"], "outputs": [".next/**", "!.next/cache/**", "public/**"], "env": [ "NEXT_PUBLIC_UMAMI_WEBSITE_ID", @@ -15,13 +24,6 @@ "DATABASE_URL", "DIRECT_URL" ] - }, - "lint": { - "outputs": [], - "inputs": ["biome.json", "src/**"] - }, - "type-check": { - "outputs": ["*.tsbuildinfo"] } } }