From b0b03cbb5f9f7b4617ecbb6bc197ce400ba96fd4 Mon Sep 17 00:00:00 2001 From: Maikel Linke Date: Thu, 22 Jan 2026 12:19:43 +1100 Subject: [PATCH 1/4] Delete old screenshots when updating app --- bin/setup | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/setup b/bin/setup index 1f75470d94..41f98b93d8 100755 --- a/bin/setup +++ b/bin/setup @@ -31,6 +31,7 @@ FileUtils.chdir APP_ROOT do puts "\n== Preparing database, removing old logs and tempfiles ==" system! "bin/rails db:prepare log:clear tmp:clear" + system! "rm -f tmp/capybara/screenshots/*.png" puts "\n== Restarting application server ==" # system! "bin/rails restart" From 6cbc6fbca3ac005b6af4cb404a875ea54f872aa6 Mon Sep 17 00:00:00 2001 From: Maikel Linke Date: Thu, 22 Jan 2026 12:27:04 +1100 Subject: [PATCH 2/4] Remove precompiled assets on update --- bin/setup | 3 +++ 1 file changed, 3 insertions(+) diff --git a/bin/setup b/bin/setup index 41f98b93d8..c31e9ab26f 100755 --- a/bin/setup +++ b/bin/setup @@ -33,6 +33,9 @@ FileUtils.chdir APP_ROOT do system! "bin/rails db:prepare log:clear tmp:clear" system! "rm -f tmp/capybara/screenshots/*.png" + puts "\n== Removing any precompiled assets that would be out of date now ==" + system! "rm -rf public/assets/" + puts "\n== Restarting application server ==" # system! "bin/rails restart" # Faster to do it manually: From 35724bec810562a6433a0af13f0f04c14b273c73 Mon Sep 17 00:00:00 2001 From: Maikel Linke Date: Thu, 22 Jan 2026 12:39:10 +1100 Subject: [PATCH 3/4] Delete generated JS for tests on update --- bin/setup | 1 + 1 file changed, 1 insertion(+) diff --git a/bin/setup b/bin/setup index c31e9ab26f..51eb039b61 100755 --- a/bin/setup +++ b/bin/setup @@ -32,6 +32,7 @@ FileUtils.chdir APP_ROOT do puts "\n== Preparing database, removing old logs and tempfiles ==" system! "bin/rails db:prepare log:clear tmp:clear" system! "rm -f tmp/capybara/screenshots/*.png" + system! "rm -f tmp/javascripts/*.js" puts "\n== Removing any precompiled assets that would be out of date now ==" system! "rm -rf public/assets/" From 85439b4b545bf96dc1793a813ce5261187497426 Mon Sep 17 00:00:00 2001 From: Maikel Linke Date: Thu, 22 Jan 2026 13:58:46 +1100 Subject: [PATCH 4/4] Delete even more tmp dev files --- bin/setup | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/bin/setup b/bin/setup index 51eb039b61..48d344fb83 100755 --- a/bin/setup +++ b/bin/setup @@ -32,10 +32,15 @@ FileUtils.chdir APP_ROOT do puts "\n== Preparing database, removing old logs and tempfiles ==" system! "bin/rails db:prepare log:clear tmp:clear" system! "rm -f tmp/capybara/screenshots/*.png" + system! "rm -f tmp/invoices/*.pdf" system! "rm -f tmp/javascripts/*.js" + system! "rm -f tmp/karma_unit.js*" + system! "rm -f tmp/product_import-*" puts "\n== Removing any precompiled assets that would be out of date now ==" system! "rm -rf public/assets/" + system! "rm -rf public/packs/" + system! "rm -rf public/packs-test/" puts "\n== Restarting application server ==" # system! "bin/rails restart"