Skip to content
Source
Sign inSign up
pingdotgg/t3code

Fix users who installed intel builds on arm macs #641

Mergedt3dotgg(GitHub profile, opens in a new tab)merged 1 commit intomain fromrefs/pull/641/headmerged by t3dotgg(GitHub profile, opens in a new tab) View on GitHub

Showing 10 changed files with 106 additions and 2 deletions (loading 7).

x
0 of 10 viewed, 10 left
17 additions and 2 deletionsapps/desktop/src/main.tsModified
View file
@@ -31,6 +31,7 @@
reduceDesktopUpdateStateOnNoUpdate,
reduceDesktopUpdateStateOnUpdateAvailable,
} from "./updateMachine";
+import { isArm64HostRunningIntelBuild, resolveDesktopRuntimeInfo } from "./runtimeArch";
​
fixPath();
​
@@ -80,7 +81,13 @@
let restoreStdIoCapture: (() => void) | null = null;
​
let destructiveMenuIconCache: Electron.NativeImage | null | undefined;
-const initialUpdateState = (): DesktopUpdateState => createInitialDesktopUpdateState(app.getVersion());
+const desktopRuntimeInfo = resolveDesktopRuntimeInfo({
+ platform: process.platform,
+ processArch: process.arch,
+ runningUnderArm64Translation: app.runningUnderARM64Translation === true,
+});
+const initialUpdateState = (): DesktopUpdateState =>
+ createInitialDesktopUpdateState(app.getVersion(), desktopRuntimeInfo);
​
function logTimestamp(): string {
return new Date().toISOString();
@@ -708,6 +715,7 @@
updateDownloadInFlight = true;
setUpdateState(reduceDesktopUpdateStateOnDownloadStart(updateState));
+ autoUpdater.disableDifferentialDownload = isArm64HostRunningIntelBuild(desktopRuntimeInfo);