I have been using Dockutil for several years and it has worked great. We are rolling out our first Catalina machines and I am having an issue. Below is my script. Chrome, Word, Excel, and Acronis Files Connect appear in the Dock just fine. These are installed applications. Calculator, Photos, and Music appear in the Dock with ? showing. These are built in Apps. How do I fix this?
!/bin/sh
LoggedInUser=$(python -c 'from SystemConfiguration import SCDynamicStoreCopyConsoleUser; import sys; username = (SCDynamicStoreCopyConsoleUser(None, None, None) or [None])[0]; username = [username,""][username in [u"loginwindow", None, u""]]; sys.stdout.write(username + "
");')
LoggedInUserHome="/Users/$LoggedInUser"
/usr/local/bin/dockutil --remove all --no-restart /Users/$3
/usr/local/bin/dockutil --add /Applications/Google Chrome.app --position 1 --no-restart $LoggedInUserHome
/usr/local/bin/dockutil --add /Applications/Microsoft Word.app --position 2 --no-restart $LoggedInUserHome
/usr/local/bin/dockutil --add /Applications/Microsoft Excel.app --position 3 --no-restart $LoggedInUserHome
/usr/local/bin/dockutil --add /Applications/Calculator.app --position 4 --no-restart $LoggedInUserHome
/usr/local/bin/dockutil --add /Applications/Acronis Files Connect.app --position 5 --no-restart $LoggedInUserHome
/usr/local/bin/dockutil --add /Applications/Photos.app --position 6 --no-restart $LoggedInUserHome
/usr/local/bin/dockutil --add /Applications/Music.app --position 7 $LoggedInUserHome
