From d42fe4f107b6e327345c1c73a0ad0ea906775970 Mon Sep 17 00:00:00 2001 From: Eugene Pankov Date: Sun, 19 May 2019 18:26:55 +0200 Subject: [PATCH] auto-create plugins folder (fixes #738) --- app/src/plugins.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/src/plugins.ts b/app/src/plugins.ts index 35a074de..c3009d45 100644 --- a/app/src/plugins.ts +++ b/app/src/plugins.ts @@ -28,6 +28,10 @@ const userPluginsPath = path.join( 'plugins', ) +if (!fs.existsSync(userPluginsPath)) { + fs.mkdir(userPluginsPath) +} + Object.assign(window, { builtinPluginsPath, userPluginsPath }) nodeModule.globalPaths.unshift(builtinPluginsPath) nodeModule.globalPaths.unshift(path.join(userPluginsPath, 'node_modules'))