Skip to content

Commit 9cce435

Browse files
authored
feat: improve clean and deep-clean scripts (#336)
1 parent 4c9950f commit 9cce435

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

package.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,18 @@
1010
],
1111
"scripts": {
1212
"test": "echo \"Error: no test specified\" && exit 1",
13-
"clean": "find . -path './node_modules' -prune -o -name 'dist' -type d -exec rm -rf '{}' \\; -printf '%p deleted\\n' 2>/dev/null",
14-
"deep-clean": "find . -name 'node_modules' -type d -prune -print -exec rm -rf '{}' \\;",
1513
"build": "turbo run build",
1614
"build:form": "turbo run build --filter=@requestnetwork/create-invoice-form",
1715
"build:dashboard": "turbo run build --filter=@requestnetwork/invoice-dashboard",
1816
"build:stakeholder": "turbo run build --filter=@requestnetwork/add-stakeholder",
1917
"build:payment-widget": "turbo run build --filter=@requestnetwork/payment-widget",
2018
"build:single-invoice": "turbo run build --filter=@requestnetwork/single-invoice",
19+
"clean": "npm run clean:dist && npm run clean:sveltekit",
20+
"clean:dist": "find . -path ./node_modules -prune -o -name 'dist' -type d -exec rm -rf '{}' + -exec echo '{}' deleted \\;",
21+
"clean:sveltekit": "find . -name '.svelte-kit' -type d -exec rm -rf '{}' + -exec echo '{}' deleted \\;",
22+
"deep-clean": "npm run clean && npm run deep-clean:turbo && npm run deep-clean:node-modules",
23+
"deep-clean:turbo": "find . -name '.turbo' -type d -exec rm -rf '{}' + -exec echo '{}' deleted \\;",
24+
"deep-clean:node-modules": "find . -name 'node_modules' -type d -exec rm -rf '{}' + -exec echo '{}' deleted \\;",
2125
"link:react": "npm link $npm_config_app_path/node_modules/react $npm_config_app_path/node_modules/react-dom",
2226
"link:all": "npm run link:react --app-path=$npm_config_app_path && for d in packages/*; do (cd $d && npm link); done",
2327
"unlink:all": "for d in packages/*; do (cd $d && npm unlink); done"

0 commit comments

Comments
 (0)