Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
ulixee
GitHub Repository: ulixee/secret-agent
Path: blob/main/replay/app.ts
1028 views
1
import '~shared/utils/sourcemap';
2
import { app } from 'electron';
3
import { platform } from 'os';
4
import log from 'electron-log';
5
6
/////// ///////////////////////////////////////////////////////////////////////////////////////////
7
import Application from './backend/Application';
8
9
// SETUP LOGGING //////////////////////////////////////////////////////////////////////////////////
10
11
console.log = log.log;
12
console.log(`Logging to ${log.transports.file.getFile().path}`);
13
14
(process.env as any).ELECTRON_DISABLE_SECURITY_WARNINGS = true;
15
16
app.name = 'SecretAgent';
17
app.allowRendererProcessReuse = true;
18
app.commandLine.appendSwitch('--enable-transparent-visuals');
19
20
process.on('uncaughtException', error => {
21
console.error(error);
22
});
23
24
app.on('window-all-closed', () => {
25
if (platform() !== 'darwin') {
26
app.quit();
27
}
28
});
29
30
Application.instance.start().catch(error => console.log('Error starting Application: ', error));
31
32