Issue:
- bless doesn't support --openfolder for Apple Silicon based architectures.
- With Rosetta transcoding the current check of os.arch() returns x86; this is why #205 did not solve the issue.
- Other node-native potential checks also fail to identify Apple Silicon environments
Fix:
- Check sysctl.proc_translated and if it has a value assume the machine is Rosetta-capable and thus Apple Silicon
Implementation:
- use sysctl command to retrieve the value of sysctl.proc_translated. If a value is returned it can be assumed the machine is Rosetta-capable.
- Do not use --openfolder when Rosetta-capability has been assumed.
By default, Github Actions Runner runs in Rosetta mode on Apple Silicon devices. This means that currently, node-appdmg won't work in a Ventura CI build environment.
Issue: - bless doesn't support
--openfolder
for Apple Silicon based architectures. - With Rosetta transcoding the current check ofos.arch()
returnsx86
; this is why #205 did not solve the issue. - Other node-native potential checks also fail to identify Apple Silicon environmentsFix: - Check
sysctl.proc_translated
and if it has a value assume the machine is Rosetta-capable and thus Apple SiliconImplementation: - use
sysctl
command to retrieve the value ofsysctl.proc_translated
. If a value is returned it can be assumed the machine is Rosetta-capable. - Do not use--openfolder
when Rosetta-capability has been assumed.Tests: - MacBook Air, 2020 (M1) - MacBook Pro, 2021 (M1 Pro)
Addresses:
216, #218, #219