We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 883ed59 commit bbb411aCopy full SHA for bbb411a
src/utils/browserPaths.ts
@@ -35,7 +35,13 @@ export const hostPlatform = ((): BrowserPlatform => {
35
const macVersion = execSync('sw_vers -productVersion', {
36
stdio: ['ignore', 'pipe', 'ignore']
37
}).toString('utf8').trim().split('.').slice(0, 2).join('.');
38
- const archSuffix = os.arch() === 'arm64' ? '-arm64' : '';
+ let arm64 = false;
39
+ if (!macVersion.startsWith('10.')) {
40
+ arm64 = execSync('sysctl -in hw.optional.arm64', {
41
+ stdio: ['ignore', 'pipe', 'ignore']
42
+ }).toString().trim() === '1';
43
+ }
44
+ const archSuffix = arm64 ? '-arm64' : '';
45
return `mac${macVersion}${archSuffix}` as BrowserPlatform;
46
}
47
if (platform === 'linux') {
0 commit comments