From 13e4d7b44b9962cdd8cfeb4f292cdf6ba66d8ec2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?F=C3=A9lix=20Pi=C3=A9dallu?= Date: Wed, 29 Nov 2023 14:41:23 +0100 Subject: [PATCH] Clean npm cache after build to reduce backup size --- scripts/_common.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/_common.sh b/scripts/_common.sh index b14bfe8..5a57462 100644 --- a/scripts/_common.sh +++ b/scripts/_common.sh @@ -30,6 +30,8 @@ _npm_build_install() { "$ynh_npm" ci --no-audit --ignore-scripts ynh_exec_warn_less ynh_exec_as "$app" env "$ynh_node_load_PATH" \ "$ynh_npm" run build + ynh_exec_warn_less ynh_exec_as "$app" env "$ynh_node_load_PATH" \ + "$ynh_npm" cache clean --force popd || ynh_die "Could not popd" ynh_secure_remove --file="$targetdir"