Closed cah-steven-murphy closed 3 years ago
This should work:
checkRosettaStatus=$(/bin/launchctl list | /usr/bin/grep "com.apple.oahd-root-helper")
(see <github.com/kandji-inc/support/blob/master/Scripts/InstallRosetta2.sh> )
Now updated to check for running oahd
process.
You could use the approach used in this installer for checking :
https://github.com/henri/install_rosetta_2
You may also want to see the way the delay is handled after the Rosetta 2 install before it is actually ready to go.
Hopefully the link above will help you out.
Testing the script with an install of macOS 11.5.0 (20G71) will install Rosetta 2 each time its run as the location its testing for the install is no longer valid.
location /Library/Apple/System/Library/LaunchDaemons/ no longer has the plist com.apple.oahd.plist so install will happen if Rosetta 2 is installed or not.