mirror of
https://github.com/zadam/trilium.git
synced 2025-11-05 04:45:47 +01:00
added "safe mode" environment variable switch which disables startup scripts and resets tabs
This commit is contained in:
@@ -22,9 +22,11 @@ function runNotesWithLabel(runAttrValue) {
|
||||
}
|
||||
|
||||
sqlInit.dbReady.then(() => {
|
||||
setTimeout(cls.wrap(() => runNotesWithLabel('backendStartup')), 10 * 1000);
|
||||
if (!process.env.TRILIUM_SAFE_MODE) {
|
||||
setTimeout(cls.wrap(() => runNotesWithLabel('backendStartup')), 10 * 1000);
|
||||
|
||||
setInterval(cls.wrap(() => runNotesWithLabel('hourly')), 3600 * 1000);
|
||||
setInterval(cls.wrap(() => runNotesWithLabel('hourly')), 3600 * 1000);
|
||||
|
||||
setInterval(cls.wrap(() => runNotesWithLabel('daily')), 24 * 3600 * 1000);
|
||||
setInterval(cls.wrap(() => runNotesWithLabel('daily')), 24 * 3600 * 1000);
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user