From a6135d6e770dc5d62c7b2bd304033b12d67319b6 Mon Sep 17 00:00:00 2001 From: JasonTaylorDev Date: Mon, 18 Nov 2024 11:32:35 +1000 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Automatically=20create=20the=20h?= =?UTF-8?q?ttps=20folder.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Web/ClientApp-React/aspnetcore-https.js | 2 ++ src/Web/ClientApp/aspnetcore-https.js | 2 ++ 2 files changed, 4 insertions(+) diff --git a/src/Web/ClientApp-React/aspnetcore-https.js b/src/Web/ClientApp-React/aspnetcore-https.js index 2bde92869..e1f96f49a 100644 --- a/src/Web/ClientApp-React/aspnetcore-https.js +++ b/src/Web/ClientApp-React/aspnetcore-https.js @@ -8,6 +8,8 @@ const baseFolder = ? `${process.env.APPDATA}/ASP.NET/https` : `${process.env.HOME}/.aspnet/https`; +if (!fs.existsSync(baseFolder)) { fs.mkdirSync(baseFolder, { recursive: true }); } + const certificateArg = process.argv.map(arg => arg.match(/--name=(?.+)/i)).filter(Boolean)[0]; const certificateName = certificateArg ? certificateArg.groups.value : process.env.npm_package_name; diff --git a/src/Web/ClientApp/aspnetcore-https.js b/src/Web/ClientApp/aspnetcore-https.js index 2bde92869..e1f96f49a 100644 --- a/src/Web/ClientApp/aspnetcore-https.js +++ b/src/Web/ClientApp/aspnetcore-https.js @@ -8,6 +8,8 @@ const baseFolder = ? `${process.env.APPDATA}/ASP.NET/https` : `${process.env.HOME}/.aspnet/https`; +if (!fs.existsSync(baseFolder)) { fs.mkdirSync(baseFolder, { recursive: true }); } + const certificateArg = process.argv.map(arg => arg.match(/--name=(?.+)/i)).filter(Boolean)[0]; const certificateName = certificateArg ? certificateArg.groups.value : process.env.npm_package_name;