Found when using Dockutil under Ventura that if you add /Applications/Safari.app, it adds a shortcut badge to the dock icon. Posting this to try to help anyone else who runs into this issue.
Solution I implemented to get around this below. I use an IF statement to set a Safari variable utilizing sw_vers in my script for setting the dock, then just referencing $safari when actually setting. This way I can still push to older devices if needed.
#Safari’s location changed in macOS 13 Ventura. If statement to supply the correct location based on OS version.
version=$(sw_vers -productVersion | awk -F '.' '{print $1}')
if [ $version -lt 13 ]; then
safari=/Applications/Safari.app
else
safari=/System/Volumes/Preboot/Cryptexes/App/System/Applications/Safari.app
fi
Found when using Dockutil under Ventura that if you add /Applications/Safari.app, it adds a shortcut badge to the dock icon. Posting this to try to help anyone else who runs into this issue.
Solution I implemented to get around this below. I use an IF statement to set a Safari variable utilizing sw_vers in my script for setting the dock, then just referencing $safari when actually setting. This way I can still push to older devices if needed.