diff --git a/packages/compass/src/main/index.ts b/packages/compass/src/main/index.ts index c60c06f3d89..aabc449076d 100644 --- a/packages/compass/src/main/index.ts +++ b/packages/compass/src/main/index.ts @@ -1,7 +1,7 @@ // THIS IMPORT SHOULD ALWAYS BE THE FIRST ONE FOR THE APPLICATION ENTRY POINT import '../setup-hadron-distribution'; -import { app, dialog } from 'electron'; +import { app, dialog, crashReporter } from 'electron'; import { handleUncaughtException } from './handle-uncaught-exception'; import { initialize as initializeElectronRemote } from '@electron/remote/main'; import { @@ -17,6 +17,8 @@ import chalk from 'chalk'; import { installEarlyLoggingListener } from './logging'; import { installEarlyOpenUrlListener } from './window-manager'; +crashReporter.start({ uploadToServer: false }); + initializeElectronRemote(); installEarlyLoggingListener(); installEarlyOpenUrlListener(); diff --git a/packages/compass/src/setup-hadron-distribution.ts b/packages/compass/src/setup-hadron-distribution.ts index f6e5553ef39..59c31ed8361 100644 --- a/packages/compass/src/setup-hadron-distribution.ts +++ b/packages/compass/src/setup-hadron-distribution.ts @@ -61,4 +61,9 @@ if ( // error here app.setPath('userCache', path.join(app.getPath('cache'), app.getName())); } + + app.setPath( + 'crashDumps', + path.join(app.getPath('userData'), 'CrashReporter') + ); }