From ffb8768b8a41cb03a96ea56a0fe2f98df9ade848 Mon Sep 17 00:00:00 2001
From: PatrykKuniczak
Date: Sat, 21 Sep 2024 21:54:06 +0200
Subject: [PATCH] fix: create script for cleaning up vite-timestamp files
---
package.json | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/package.json b/package.json
index 20013f224..c9a2c9be4 100644
--- a/package.json
+++ b/package.json
@@ -9,13 +9,14 @@
},
"type": "module",
"scripts": {
+ "clean:vite": "bash -c \"find . -type f -name 'vite.config.*.timestamp-*' ! -path './node_modules/*' -ls -delete 2>/dev/null\"",
"clean:bundle": "rimraf dist && rimraf dist-zip && turbo clean:bundle",
"clean:node_modules": "turbo daemon stop && pnpx rimraf node_modules && pnpx turbo clean:node_modules",
"clean:turbo": "turbo daemon stop && rimraf .turbo && turbo clean:turbo",
"clean": "pnpm clean:bundle && pnpm clean:turbo && pnpm clean:node_modules",
"clean:install": "pnpm clean:node_modules && pnpm install --frozen-lockfile",
- "build": "pnpm clean:bundle && turbo ready && turbo build",
- "build:firefox": "pnpm clean:bundle && turbo ready && cross-env __FIREFOX__=true turbo build",
+ "build": "pnpm clean:bundle && turbo ready && turbo build && pnpm clean:vite",
+ "build:firefox": "pnpm clean:bundle && turbo ready && cross-env __FIREFOX__=true turbo build && pnpm clean:vite",
"zip": "pnpm build && pnpm -F zipper zip",
"zip:firefox": "pnpm build:firefox && cross-env __FIREFOX__=true pnpm -F zipper zip",
"dev": "turbo ready && cross-env __DEV__=true turbo watch dev --concurrency 20",