feat: New one-click Home Server, now in Labs. Launch your own self-hosted server instance with just 1 click from the Preferences window. (#2341)

This commit is contained in:
Mo
2023-07-03 08:30:48 -05:00
committed by GitHub
parent d79e7b14b1
commit 96f42643a9
367 changed files with 5895 additions and 570 deletions

View File

@@ -11,6 +11,8 @@ export enum StoreKeys {
UseNativeKeychain = 'useNativeKeychain',
LastRunVersion = 'LastRunVersion',
HomeServerDataLocation = 'HomeServerDataLocation',
LegacyTextBackupsLocation = 'backupsLocation',
LegacyTextBackupsDisabled = 'backupsDisabled',

View File

@@ -1,9 +1,9 @@
import fs from 'fs'
import { Language } from '../SpellcheckerManager'
import { FileDoesNotExist } from '../Utils/FileUtils'
import { ensureIsBoolean, isBoolean } from '../Utils/Utils'
import { StoreData, StoreKeys } from './StoreKeys'
import { logError } from './Store'
import { FileErrorCodes } from '../File/FileErrorCodes'
export function createSanitizedStoreData(data: any = {}): StoreData {
return {
@@ -69,7 +69,7 @@ export function parseDataFile(filePath: string) {
return createSanitizedStoreData(userData)
} catch (error: any) {
console.log('Error reading store file', error)
if (error.code !== FileDoesNotExist) {
if (error.code !== FileErrorCodes.FileDoesNotExist) {
logError(error)
}