Merge branch 'master' of github.com:symphonyoss/SymphonyElectron

This commit is contained in:
Vishwas Shashidhar 2020-06-15 12:13:32 +05:30
commit 109383e07f
5 changed files with 48 additions and 14 deletions

View File

@ -0,0 +1 @@
014EDEDF-E632-4E53-AAEC-B4FC8AF1E72D

View File

@ -4,8 +4,10 @@
settingsFilePath='/tmp/sym_settings.txt'
permissionsFilePath='/tmp/sym_permissions.txt'
installPath="$2"
configPath="/Symphony.app/Contents/config/Symphony.config"
newPath=${installPath}${configPath}
configPath="/Symphony.app/Contents/config"
configFilePath="${installPath}${configPath}/Symphony.config"
installVariantPath="${installPath}${configPath}/InstallVariant.info"
newPath=${configFilePath}
## Get Symphony Settings from the temp file ##
pod_url=$(sed -n '1p' ${settingsFilePath});
@ -62,3 +64,5 @@ sed -i "" -E "s#\"openExternal\" ?: ?([Tt][Rr][Uu][Ee]|[Ff][Aa][Ll][Ss][Ee])#\"o
## Remove the temp settings & permissions file created ##
rm -f ${settingsFilePath}
rm -f ${permissionsFilePath}
uuidgen > ${installVariantPath}

View File

@ -30,6 +30,7 @@
<ROW Property="FULL_SCREEN" Value="true"/>
<ROW Property="FULL_SCREEN_CB" Value="true"/>
<ROW Property="FileInUseProcess" Value="Symphony.exe" Type="4"/>
<ROW Property="INSTALL_VARIANT" Value="014EDEDF-E632-4E53-AAEC-B4FC8AF1E72D"/>
<ROW Property="LOCATION" Value="true"/>
<ROW Property="MEDIA" Value="true"/>
<ROW Property="MIDI_SYSEX" Value="true"/>
@ -164,6 +165,7 @@
<COMPONENT cid="caphyon.advinst.msicomp.MsiFilesComponent">
<ROW File="CODE_OF_CONDUCT.md_2" Component_="build.cmd" FileName="CODE_O~1.MD|CODE_OF_CONDUCT.md" Attributes="0" SourcePath="..\..\dist\win-unpacked\resources\app.asar.unpacked\node_modules\spawn-rx\CODE_OF_CONDUCT.md" SelfReg="false" NextFile="COPYING"/>
<ROW File="COPYING" Component_="build.cmd" FileName="COPYING" Attributes="0" SourcePath="..\..\dist\win-unpacked\resources\app.asar.unpacked\node_modules\spawn-rx\COPYING" SelfReg="false" NextFile="esdoc.json"/>
<ROW File="InstallVariant.info" Component_="Symphony.config" FileName="INSTAL~1.INF|InstallVariant.info" Attributes="0" SourcePath="..\..\dist\win-unpacked\config\InstallVariant.info" SelfReg="false"/>
<ROW File="Jobber.exe" Component_="Jobber.exe" FileName="Jobber.exe" Attributes="0" SourcePath="..\..\dist\win-unpacked\resources\app.asar.unpacked\node_modules\spawn-rx\vendor\jobber\Jobber.exe" SelfReg="false" NextFile="libEGL.dll_1" DigSign="true"/>
<ROW File="LICENSE.electron.txt" Component_="blink_image_resources_200_percent.pak" FileName="LICENS~1.TXT|LICENSE.electron.txt" Attributes="0" SourcePath="..\..\dist\win-unpacked\LICENSE.electron.txt" SelfReg="false" NextFile="LICENSES.chromium.html"/>
<ROW File="LICENSES.chromium.html" Component_="blink_image_resources_200_percent.pak" FileName="LICENS~1.HTM|LICENSES.chromium.html" Attributes="0" SourcePath="..\..\dist\win-unpacked\LICENSES.chromium.html" SelfReg="false" NextFile="Symphony.exe"/>
@ -176,7 +178,7 @@
<ROW File="ar.pak" Component_="am.pak" FileName="ar.pak" Attributes="0" SourcePath="..\..\dist\win-unpacked\locales\ar.pak" SelfReg="false" NextFile="bg.pak"/>
<ROW File="bg.pak" Component_="am.pak" FileName="bg.pak" Attributes="0" SourcePath="..\..\dist\win-unpacked\locales\bg.pak" SelfReg="false" NextFile="bn.pak"/>
<ROW File="binding.node" Component_="binding.node" FileName="BINDIN~1.NOD|binding.node" Attributes="0" SourcePath="..\..\dist\win-unpacked\resources\app.asar.unpacked\node_modules\ref-napi\build\Release\binding.node" SelfReg="false" NextFile="build.cmd"/>
<ROW File="binding.node_1" Component_="binding.node_1" FileName="BINDIN~1.NOD|binding.node" Attributes="0" SourcePath="..\..\dist\win-unpacked\resources\app.asar.unpacked\node_modules\swift-search\node_modules\ref-napi\build\Release\binding.node" SelfReg="false"/>
<ROW File="binding.node_1" Component_="binding.node_1" FileName="BINDIN~1.NOD|binding.node" Attributes="0" SourcePath="..\..\dist\win-unpacked\resources\app.asar.unpacked\node_modules\swift-search\node_modules\ref-napi\build\Release\binding.node" SelfReg="false" NextFile="InstallVariant.info"/>
<ROW File="bn.pak" Component_="am.pak" FileName="bn.pak" Attributes="0" SourcePath="..\..\dist\win-unpacked\locales\bn.pak" SelfReg="false" NextFile="ca.pak"/>
<ROW File="build.cmd" Component_="build.cmd" FileName="build.cmd" Attributes="0" SourcePath="..\..\dist\win-unpacked\resources\app.asar.unpacked\node_modules\spawn-rx\build.cmd" SelfReg="false" NextFile="build.sh"/>
<ROW File="build.sh" Component_="build.cmd" FileName="build.sh" Attributes="0" SourcePath="..\..\dist\win-unpacked\resources\app.asar.unpacked\node_modules\spawn-rx\build.sh" SelfReg="false" NextFile="CODE_OF_CONDUCT.md_2"/>
@ -448,7 +450,7 @@
<ROW Dialog_="VerifyReadyDlg" Control_="Back" Event="NewDialog" Argument="PatchWelcomeDlg" Condition="AI_PATCH" Ordering="203"/>
<ROW Dialog_="InstallTypeDlg" Control_="Next" Event="EndDialog" Argument="Return" Condition="AI_INSTALL AND ( AI_PROCESS_STATE=&quot;Stopped&quot; )" Ordering="105"/>
<ROW Dialog_="InstallationDlg" Control_="Cancel" Event="SpawnDialog" Argument="CancelDlg" Condition="1" Ordering="100"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="EndDialog" Argument="Return" Condition="AI_INSTALL" Ordering="13"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="EndDialog" Argument="Return" Condition="AI_INSTALL" Ordering="16"/>
<ROW Dialog_="InstallationDlg" Control_="Browse" Event="[_BrowseProperty]" Argument="APPDIR" Condition="1" Ordering="100"/>
<ROW Dialog_="InstallationDlg" Control_="Browse" Event="SpawnDialog" Argument="BrowseDlg" Condition="1" Ordering="200"/>
<ROW Dialog_="InstallationDlg" Control_="Back" Event="SpawnDialog" Argument="InstallTypeDlg" Condition="AI_INSTALL" Ordering="1"/>
@ -534,9 +536,9 @@
<ROW Dialog_="CloseSymphonyDialog" Control_="Back" Event="DoAction" Argument="AI_DATA_SETTER_2" Condition="1" Ordering="1"/>
<ROW Dialog_="InstallTypeDlg" Control_="Next" Event="DoAction" Argument="AI_DATA_SETTER_2" Condition="AI_INSTALL" Ordering="101"/>
<ROW Dialog_="InstallTypeDlg" Control_="Next" Event="SpawnDialog" Argument="CloseSymphonyDialog" Condition="AI_INSTALL AND ( AI_PROCESS_STATE=&quot;Running&quot; )" Ordering="103"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="SpawnDialog" Argument="OutOfRbDiskDlg" Condition="AI_INSTALL AND OutOfDiskSpace = 1 AND OutOfNoRbDiskSpace = 0 AND (PROMPTROLLBACKCOST=&quot;P&quot; OR NOT PROMPTROLLBACKCOST)" Ordering="14" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="EnableRollback" Argument="False" Condition="AI_INSTALL AND OutOfDiskSpace = 1 AND OutOfNoRbDiskSpace = 0 AND PROMPTROLLBACKCOST=&quot;D&quot;" Ordering="15" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="SpawnDialog" Argument="OutOfDiskDlg" Condition="AI_INSTALL AND ( (OutOfDiskSpace = 1 AND OutOfNoRbDiskSpace = 1) OR (OutOfDiskSpace = 1 AND PROMPTROLLBACKCOST=&quot;F&quot;) )" Ordering="16" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="SpawnDialog" Argument="OutOfRbDiskDlg" Condition="AI_INSTALL AND OutOfDiskSpace = 1 AND OutOfNoRbDiskSpace = 0 AND (PROMPTROLLBACKCOST=&quot;P&quot; OR NOT PROMPTROLLBACKCOST)" Ordering="17" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="EnableRollback" Argument="False" Condition="AI_INSTALL AND OutOfDiskSpace = 1 AND OutOfNoRbDiskSpace = 0 AND PROMPTROLLBACKCOST=&quot;D&quot;" Ordering="18" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="SpawnDialog" Argument="OutOfDiskDlg" Condition="AI_INSTALL AND ( (OutOfDiskSpace = 1 AND OutOfNoRbDiskSpace = 1) OR (OutOfDiskSpace = 1 AND PROMPTROLLBACKCOST=&quot;F&quot;) )" Ordering="19" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="InstallationDlgDialogInitializer" Event="[AI_ButtonText_Next_Orig]" Argument="[ButtonText_Next]" Condition="AI_INSTALL" Ordering="1" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="InstallationDlgDialogInitializer" Event="[ButtonText_Next]" Argument="[[AI_CommitButton]]" Condition="AI_INSTALL" Ordering="2" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="InstallationDlgDialogInitializer" Event="[AI_Text_Next_Orig]" Argument="[Text_Next]" Condition="AI_INSTALL" Ordering="3" Options="2"/>
@ -544,6 +546,8 @@
<ROW Dialog_="InstallationDlg" Control_="Back" Event="[ButtonText_Next]" Argument="[AI_ButtonText_Next_Orig]" Condition="AI_INSTALL" Ordering="2" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="Back" Event="[Text_Next]" Argument="[AI_Text_Next_Orig]" Condition="AI_INSTALL" Ordering="3" Options="2"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="DoAction" Argument="SetDefaults" Condition="AI_INSTALL" Ordering="12"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="DoAction" Argument="UpdateInstallVariant" Condition="AI_INSTALL" Ordering="15"/>
<ROW Dialog_="InstallationDlg" Control_="Next" Event="DoAction" Argument="AI_DATA_SETTER" Condition="AI_INSTALL" Ordering="14"/>
</COMPONENT>
<COMPONENT cid="caphyon.advinst.msicomp.MsiCreateFolderComponent">
<ROW Directory_="Symphony_Dir" Component_="Symphony" ManualDelete="false"/>
@ -556,6 +560,7 @@
<ROW Action="AI_AiRestoreDeferredImpersonate" Type="9217" Source="ResourceCleaner.dll" Target="OnAiRestoreDeferredImpersonate"/>
<ROW Action="AI_AiRestoreRollback" Type="11521" Source="ResourceCleaner.dll" Target="OnAiRestoreRollback" WithoutSeq="true"/>
<ROW Action="AI_AuthorSinglePackage" Type="1" Source="aicustact.dll" Target="AI_AuthorSinglePackage" WithoutSeq="true"/>
<ROW Action="AI_DATA_SETTER" Type="51" Source="CustomActionData" Target="AEkAcwA2ADQAQgBpAHQAAgABAFAAYQByAGEAbQBzAAIAAQBTAGMAcgBpAHAAdAACACMAIABCAGwAbwBjAGsAIABmAG8AcgAgAGQAZQBjAGwAYQByAGkAbgBnACAAdABoAGUAIABzAGMAcgBpAHAAdAAgAHAAYQByAGEAbQBlAHQAZQByAHMALgANAAoAUABhAHIAYQBtACgAKQANAAoADQAKACMAIABZAG8AdQByACAAYwBvAGQAZQAgAGcAbwBlAHMAIABoAGUAcgBlAC4ADQAKAGYAdQBuAGMAdABpAG8AbgAgAHUAdQBpAGQAIABbAFwAewBdACAAWwBcAFsAXQBnAHUAaQBkAFsAXABdAF0AOgA6AE4AZQB3AEcAdQBpAGQAKAApAC4AVABvAFMAdAByAGkAbgBnACgAKQAgAFsAXAB9AF0ADQAKACQAdQB1AGkAZABfAHYAYQBsAHUAZQAgAD0AIAB1AHUAaQBkAA0ACgBBAEkAXwBTAGUAdABNAHMAaQBQAHIAbwBwAGUAcgB0AHkAIABJAE4AUwBUAEEATABMAF8AVgBBAFIASQBBAE4AVAAgACQAdQB1AGkAZABfAHYAYQBsAHUAZQ=="/>
<ROW Action="AI_DATA_SETTER_1" Type="51" Source="CustomActionData" Target="AEkAcwA2ADQAQgBpAHQAAgABAFAAYQByAGEAbQBzAAIAAQBTAGMAcgBpAHAAdAACACMAIABCAGwAbwBjAGsAIABmAG8AcgAgAGQAZQBjAGwAYQByAGkAbgBnACAAdABoAGUAIABzAGMAcgBpAHAAdAAgAHAAYQByAGEAbQBlAHQAZQByAHMALgANAAoAUABhAHIAYQBtACgAKQANAAoADQAKACMAIABZAG8AdQByACAAYwBvAGQAZQAgAGcAbwBlAHMAIABoAG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AbwB0ACAASABLAEUAWQBfAFUAUwBFAFIAUwAgAC0ARQByAHIAbwByAEEAYwB0AGkAbwBuACAAUwBpAGwAZQBuAHQAbAB5AEMAbwBuAHQAaQBuAHUAZQANAAoAUgBlAG0AbwB2AGUALQBJAHQAZQBtAFAAcgBvAHAAZQByAHQAeQAgAC0AUABhAHQAaAAgACIASABLAFUAOgAuAEQARQBGAEEAVQBMAFQAXABTAG8AZgB0AHcAYQByAGUAXABNAGkAYwByAG8AcwBvAGYAdABcAFcAaQBuAGQAbwB3AHMAXABDAHUAcgByAGUAbgB0AFYAZQByAHMAaQBvAG4AXABSAHUAbgAiACAALQBOAGEAbQBlACAAIgBTAHkAbQBwAGgAbwBuAHkAIgAgAC0ARQByAHIAbwByAEEAYwB0AGkAbwBuACAAUwBpAGwAZQBuAHQAbAB5AEMAbwBuAHQAaQBuAHUAZQ=="/>
<ROW Action="AI_DATA_SETTER_2" Type="51" Source="CustomActionData" Target="Symphony.exe"/>
<ROW Action="AI_DATA_SETTER_4" Type="51" Source="CustomActionData" Target="Symphony.exe"/>
@ -583,6 +588,7 @@
<ROW Action="SetDefaults" Type="37" Target="Script Text" TargetUnformatted="if (!Session.Property(&quot;POD_URL&quot;)) {&#13;&#10;&#9;Session.Property(&quot;POD_URL&quot;) = &quot;https://my.symphony.com&quot;;&#13;&#10;} else {&#13;&#10;&#9;Session.Property(&quot;POD_URL&quot;) = Session.Property(&quot;POD_URL&quot;).replace(/^\s\s*/, &apos;&apos;).replace(/\s\s*$/, &apos;&apos;);&#13;&#10;}&#13;&#10;&#13;&#10;var autoLaunchPath = Session.Property(&quot;AUTO_LAUNCH_PATH&quot;);&#13;&#10;if (autoLaunchPath) {&#13;&#10;&#9;Session.Property(&quot;AUTO_LAUNCH_PATH&quot;) = autoLaunchPath.replace(/\\/g, &quot;/&quot;);&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;ALWAYS_ON_TOP&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;ALWAYS_ON_TOP&quot;) = &quot;DISABLED&quot;; &#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;MINIMIZE_ON_CLOSE&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;MINIMIZE_ON_CLOSE&quot;) = &quot;ENABLED&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;AUTO_START&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;AUTO_START&quot;) = &quot;ENABLED&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;BRING_TO_FRONT&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;BRING_TO_FRONT&quot;) = &quot;DISABLED&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;CUSTOM_TITLE_BAR&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;CUSTOM_TITLE_BAR&quot;) = &quot;ENABLED&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;DEV_TOOLS_ENABLED&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;DEV_TOOLS_ENABLED&quot;) = &quot;true&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;MEDIA&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;MEDIA&quot;) = &quot;true&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;LOCATION&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;LOCATION&quot;) = &quot;true&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;NOTIFICATIONS&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;NOTIFICATIONS&quot;) = &quot;true&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;MIDI_SYSEX&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;MIDI_SYSEX&quot;) = &quot;true&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;POINTER_LOCK&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;POINTER_LOCK&quot;) = &quot;true&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;FULL_SCREEN&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;FULL_SCREEN&quot;) = &quot;true&quot;;&#13;&#10;}&#13;&#10;&#13;&#10;if (!Session.Property(&quot;OPEN_EXTERNAL&quot;))&#13;&#10;{&#13;&#10;&#9;Session.Property(&quot;OPEN_EXTERNAL&quot;) = &quot;true&quot;;&#13;&#10;}&#13;&#10;" WithoutSeq="true"/>
<ROW Action="StopProcess" Type="65" Source="aicustact.dll" Target="StopProcess" WithoutSeq="true" Options="1" AdditionalSeq="AI_DATA_SETTER_4"/>
<ROW Action="UninstallPreviousVersions" Type="65" Source="aicustact.dll" Target="UninstallPreviousVersions" Options="1"/>
<ROW Action="UpdateInstallVariant" Type="1" Source="PowerShellScriptLauncher.dll" Target="RunPowerShellScript" WithoutSeq="true" Options="1" AdditionalSeq="AI_DATA_SETTER"/>
</COMPONENT>
<COMPONENT cid="caphyon.advinst.msicomp.MsiDialogComponent">
<ROW Dialog="CloseSymphonyDialog" HCentering="50" VCentering="50" Width="370" Height="270" Attributes="3" Title="[ProductName] [Setup]" Control_Default="Next" Control_Cancel="Cancel"/>
@ -691,8 +697,10 @@
<ROW Name="CustomTitleBar" TxtUpdateSet="Symphony.config" FindPattern="&quot;isCustomTitleBar&quot;\s*:\s*&quot;ENABLED&quot;," ReplacePattern="&quot;isCustomTitleBar&quot; : &quot;[CUSTOM_TITLE_BAR]&quot;," Options="19" Order="12" FileEncoding="-1"/>
<ROW Name="DevTools" TxtUpdateSet="Symphony.config" FindPattern="&quot;devToolsEnabled&quot;\s*:\s*true," ReplacePattern="&quot;devToolsEnabled&quot; : [DEV_TOOLS_ENABLED]," Options="19" Order="13" FileEncoding="-1"/>
<ROW Name="AutoLaunchPath" TxtUpdateSet="Symphony.config" FindPattern="&quot;autoLaunchPath&quot;\s*:\s*&quot;&quot;" ReplacePattern="&quot;autoLaunchPath&quot; : &quot;[AUTO_LAUNCH_PATH]&quot;" Options="19" Order="14" FileEncoding="-1"/>
<ROW Name="SetUUID" TxtUpdateSet="InstallVariant.info" FindPattern="014EDEDF-E632-4E53-AAEC-B4FC8AF1E72D" ReplacePattern="[INSTALL_VARIANT]" Options="0" Order="0" FileEncoding="-1"/>
</COMPONENT>
<COMPONENT cid="caphyon.advinst.msicomp.TxtUpdateSetComponent">
<ROW Key="InstallVariant.info" Component="am.pak" FileName="InstallVariant.info" Directory="config_Dir" Options="17"/>
<ROW Key="Symphony.config" Component="am.pak" FileName="Symphony.config" Directory="config_Dir" Options="17"/>
</COMPONENT>
</DOCUMENT>

View File

@ -55,6 +55,7 @@
"extraFiles": [
"config/Symphony.config",
"config/titleBarStyles.css",
"config/InstallVariant.info",
"dictionaries/**",
"library/libsymphonysearch.dylib",
"library/indexvalidator.exec",

View File

@ -37,6 +37,7 @@ export interface IConfig {
notificationSettings: INotificationSetting;
mainWinPos?: ICustomRectangle;
locale?: string;
installVariant?: string;
}
export interface IGlobalConfig {
@ -113,7 +114,10 @@ class Config {
public cloudConfig: ICloudConfig | {};
public filteredCloudConfig: ICloudConfig | {};
private isFirstTime: boolean = true;
private installVariant: string | undefined;
private readonly configFileName: string;
private readonly installVariantFilename: string;
private readonly installVariantPath: string;
private readonly userConfigPath: string;
private readonly appPath: string;
private readonly globalConfigPath: string;
@ -121,6 +125,7 @@ class Config {
constructor() {
this.configFileName = 'Symphony.config';
this.installVariantFilename = 'InstallVariant.info';
this.userConfigPath = path.join(app.getPath('userData'), this.configFileName);
this.cloudConfigPath = path.join(app.getPath('userData'), 'cloudConfig.config');
this.appPath = isDevEnv ? app.getAppPath() : path.dirname(app.getPath('exe'));
@ -128,8 +133,13 @@ class Config {
? path.join(this.appPath, path.join('config', this.configFileName))
: path.join(this.appPath, (isMac) ? '..' : '', 'config', this.configFileName);
this.installVariantPath = isDevEnv
? path.join(this.appPath, path.join('config', this.installVariantFilename))
: path.join(this.appPath, (isMac) ? '..' : '', 'config', this.installVariantFilename);
if (isLinux) {
this.globalConfigPath = path.join(this.appPath, (isElectronQA) ? '..' : '', 'config', this.configFileName);
this.installVariantPath = path.join(this.appPath, (isElectronQA) ? '..' : '', 'config', this.installVariantFilename);
}
this.globalConfig = {};
@ -138,6 +148,7 @@ class Config {
this.filteredCloudConfig = {};
this.readUserConfig();
this.readGlobalConfig();
this.readInstallVariant();
this.readCloudConfig();
this.checkFirstTimeLaunch();
@ -263,10 +274,11 @@ class Config {
...filteredFields }: IConfig = this.userConfig as IConfig;
// update to the new build number
filteredFields.buildNumber = buildNumber;
filteredFields.installVariant = this.installVariant;
logger.info(`config-handler: setting first time launch for build`, buildNumber);
return await this.updateUserConfig(filteredFields);
}
await this.updateUserConfig({ buildNumber });
await this.updateUserConfig({ buildNumber, installVariant: this.installVariant });
}
/**
@ -332,6 +344,14 @@ class Config {
logger.info(`config-handler: Global configuration: `, this.globalConfig);
}
/**
* Reads the install variant from a file
*/
private readInstallVariant() {
this.installVariant = fs.readFileSync(this.installVariantPath, 'utf8');
logger.info(`config-handler: Install variant: `, this.installVariant);
}
/**
* Reads and stores the cloud config file
*
@ -354,20 +374,20 @@ class Config {
*/
private async checkFirstTimeLaunch() {
logger.info('config-handler: checking first time launch');
const configBuildNumber = this.userConfig && (this.userConfig as IConfig).buildNumber || null;
const installVariant = this.userConfig && (this.userConfig as IConfig).installVariant || null;
if (!configBuildNumber) {
logger.info(`config-handler: there's no build number found, this is a first time launch`);
if (!installVariant) {
logger.info(`config-handler: there's no install variant found, this is a first time launch`);
this.isFirstTime = true;
return;
}
if (configBuildNumber && typeof configBuildNumber === 'string' && configBuildNumber !== buildNumber) {
logger.info(`config-handler: build number found is of an older build, this is a first time launch`);
if (installVariant && typeof installVariant === 'string' && installVariant !== this.installVariant) {
logger.info(`config-handler: install variant found is of a different instance, this is a first time launch`);
this.isFirstTime = true;
return;
}
logger.info(`config-handler: build number is the same as the previous build, not a first time launch`);
logger.info(`config-handler: install variant is the same as the existing one, not a first time launch`);
this.isFirstTime = false;
}
}