aboutsummaryrefslogtreecommitdiffstats
path: root/packages/main/src/index.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/main/src/index.ts')
-rw-r--r--packages/main/src/index.ts7
1 files changed, 6 insertions, 1 deletions
diff --git a/packages/main/src/index.ts b/packages/main/src/index.ts
index 0530e32..f56d629 100644
--- a/packages/main/src/index.ts
+++ b/packages/main/src/index.ts
@@ -39,6 +39,11 @@ import { createRootStore } from './stores/RootStore';
39const isSingleInstance = app.requestSingleInstanceLock(); 39const isSingleInstance = app.requestSingleInstanceLock();
40const isDevelopment = import.meta.env.MODE === 'development'; 40const isDevelopment = import.meta.env.MODE === 'development';
41 41
42// Use alternative directory when debugging to avoid clobbering the main installation.
43if (isDevelopment) {
44 app.setPath('userData', `${app.getPath('userData')}-dev`);
45}
46
42if (!isSingleInstance) { 47if (!isSingleInstance) {
43 app.quit(); 48 app.quit();
44 process.exit(0); 49 process.exit(0);
@@ -124,7 +129,7 @@ async function createWindow(): Promise<void> {
124 const browserView = new BrowserView({ 129 const browserView = new BrowserView({
125 webPreferences: { 130 webPreferences: {
126 sandbox: true, 131 sandbox: true,
127 partition: 'service', 132 partition: 'persist:service',
128 }, 133 },
129 }); 134 });
130 135