This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# If cpu is Apple branded, install Rosetta 2 | |
if [[ "$(sysctl -n machdep.cpu.brand_string)" == *'Apple'* ]]; then | |
/usr/sbin/softwareupdate --install-rosetta --agree-to-license | |
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# If cpu is Apple branded, use arch binary to check if x86_64 code can run | |
if [[ "$(sysctl -n machdep.cpu.brand_string)" == *'Apple'* ]]; then | |
if arch -x86_64 /usr/bin/true 2> /dev/null; then | |
result="Installed" | |
else | |
result="Missing" | |
fi | |
else |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Location of macOS Build plist for comparison | |
# Subsitute your org name for anyOrg, or place in another location | |
buildPlist="/usr/local/anyOrg/macOSBuild.plist" | |
# Get the local os build version | |
# Using build version accounts for supplimental updates as well as dot updates and os upgrades | |
localOS=$( /usr/bin/sw_vers | awk '/BuildVersion/{print $2}' ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Location of macOS Build plist for comparison | |
# Subsitute your org name for anyOrg, or place in another location | |
buildPlist="/usr/local/anyOrg/macOSBuild.plist" | |
# Get the local os build version | |
# Using build version accounts for supplimental updates as well as dot updates and os upgrades | |
localOS=$( /usr/bin/sw_vers | awk '/BuildVersion/{print $2}' ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# Set the icons and branding | |
selfServiceBrandIcon="/Users/$3/Library/Application Support/com.jamfsoftware.selfservice.mac/Documents/Images/brandingimage.png" | |
fileVaultIcon="/System/Library/CoreServices/CoreTypes.bundle/Contents/Resources/FileVaultIcon.icns" | |
if [[ -f $selfServiceBrandIcon ]]; then | |
brandIcon="$selfServiceBrandIcon" | |
else | |
brandIcon="$fileVaultIcon" |
NewerOlder