From 1df4494979b68060eb8fee4b57b90855582b2902 Mon Sep 17 00:00:00 2001 From: Adrian Marten Date: Mon, 17 Oct 2022 23:04:41 +0200 Subject: [PATCH] Fixed source-map handling for git --- app/.gitignore | 2 ++ app/uglify-assets.js | 3 +++ 2 files changed, 5 insertions(+) diff --git a/app/.gitignore b/app/.gitignore index 457db690..8402ee1f 100644 --- a/app/.gitignore +++ b/app/.gitignore @@ -50,3 +50,5 @@ Thumbs.db # test-time: code service dist-codeservice + +/source_maps diff --git a/app/uglify-assets.js b/app/uglify-assets.js index 897f77dd..7d16ccfc 100644 --- a/app/uglify-assets.js +++ b/app/uglify-assets.js @@ -4,6 +4,9 @@ const path = require("path"); const asset_script_path = "dist/assets/scripts/"; const map_path = "source_maps"; +if (!fs.existsSync(path.join(__dirname, map_path))) { + fs.mkdirSync(path.join(__dirname, map_path)); +} const options = { compress: {