Posted on 01-25-2018 05:35 AM
hi - i'm trying to remove a default macOS dock items by using the following command:
sudo /Users/joeblow/dockutil-master/scripts/dockutil --remove "/Applications/Siri.app" --allhomes
the error:
item /Applications/Siri.app was not found in /Users/joeblow/Library/Preferences/com.apple.dock.plist
thanks for any insight.
Posted on 01-25-2018 05:49 AM
Do you install also the dockutil on the mac?
try this one:
#!/bin/bash
currentUser=$(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 + "
");')
/usr/local/bin/dockutil --remove "Siri" /Users/${currentUser}
exit 0
Posted on 01-25-2018 06:09 AM
thanks ICTMuttenz. working now
Posted on 01-26-2018 06:15 AM
just 2 follow-up questions.
1) is it possible to do more than 1 items removal using 1 command. i tried to do by adding another app but failed.
2) when i tried to use a similar command, the item gets added but with a question mark on the dock.
here's my syntax:
sudo /Users/$log/.dock/dockutil-master/scripts/dockutil --add "Adium" /Users/$log
or sudo /Users/$log/.dock/dockutil-master/scripts/dockutil --add "/Applications/Adium" /Users/$log
please assist. thx
Posted on 01-26-2018 08:30 AM
This isn't my code, but you might want to have a look at DockutilAddRemoveArrays.sh this will let you hundle multiple items.
Posted on 03-22-2018 11:21 AM
@tranatisoc do you still ned help?