Removing finder sidebar items?

cpizanias
Contributor

What's the best way to go about this? I saw people recommending mysides but xcode hates me and I can't compile it for some reason. Can someone put it up on dropbox or something? https://github.com/mosen/mysides

Conversely is there a way to remove finder sidebar items using sfltool? If there is i'm not seeing a way. Thanks!

1 ACCEPTED SOLUTION

djdavetrouble
Contributor III

i run this once per user per computer scoped at login.

/usr/local/bin/mysides remove All My Files file:///System/Library/CoreServices/Finder.app/Contents/Resources/MyLibraries/myDocuments.cannedSearch/
/usr/local/bin/mysides remove iCloud x-apple-finder:icloud
/usr/local/bin/mysides remove domain-AirDrop nwnode://domain-AirDrop
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Desktop
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Documents
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Downloads
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Movies
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Music
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Pictures
touch /Users/$3/.sidebarshortcuts
killall cfprefsd
sleep 1
/usr/libexec/PlistBuddy -c "Add :networkbrowser:CustomListProperties:com.apple.NetworkBrowser.backToMyMacEnabled bool False" /Users/$3/Library/Preferences/com.apple.sidebarlists.plist
/usr/libexec/PlistBuddy -c "Add :networkbrowser:CustomListProperties:com.apple.NetworkBrowser.bonjourEnabled bool False" /Users/$3/Library/Preferences/com.apple.sidebarlists.plist

View solution in original post

13 REPLIES 13

scottb
Honored Contributor

djdavetrouble
Contributor III

i run this once per user per computer scoped at login.

/usr/local/bin/mysides remove All My Files file:///System/Library/CoreServices/Finder.app/Contents/Resources/MyLibraries/myDocuments.cannedSearch/
/usr/local/bin/mysides remove iCloud x-apple-finder:icloud
/usr/local/bin/mysides remove domain-AirDrop nwnode://domain-AirDrop
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Desktop
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Documents
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Downloads
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Movies
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Music
/usr/bin/sfltool add-item com.apple.LSSharedFileList.FavoriteItems file:///Users/$3/Pictures
touch /Users/$3/.sidebarshortcuts
killall cfprefsd
sleep 1
/usr/libexec/PlistBuddy -c "Add :networkbrowser:CustomListProperties:com.apple.NetworkBrowser.backToMyMacEnabled bool False" /Users/$3/Library/Preferences/com.apple.sidebarlists.plist
/usr/libexec/PlistBuddy -c "Add :networkbrowser:CustomListProperties:com.apple.NetworkBrowser.bonjourEnabled bool False" /Users/$3/Library/Preferences/com.apple.sidebarlists.plist

djdavetrouble
Contributor III

there is a pkg on the releases page:
https://github.com/mosen/mysides/releases

cpizanias
Contributor

Thanks all!

francksartori
New Contributor III

Hi.
Did you find any instructions to build this project ?
I've downloaded it and built Products > mysides (so it is "black").
Then I launch the provided Makefile script but it fails to put the binary in a package and then in a disk image.
So I've done a Control-Click on Products > mysides, then "Show in Finder" so I can grab the binary from a Xcode debug folder.
Do you have any hints to make the building normal ?
Best regards.
Franck.

cpizanias
Contributor

@francksartori I couldn't figure it out either so what I did was find the recipe for it on Autopkg and used it that way.

francksartori
New Contributor III

Hi.
See also : https://github.com/mosen/mysides/issues/6
Unfortunately, the binary is not reliably usable.
Best regards.

JayDuff
Contributor II

Is there any reason NOT to use Composer's User Environment > Sidebar feature? Then you check FEU and FUT and deploy on first boot.

Wakko
Contributor II

@JayDuff I 100% agree with you. Why load something else up when you can do it this tried and proven way.

L3nny5
New Contributor III

Does using Composer's User Environment > Sidebar feature still work for you? For me it only adds some of the changes I made. Custom folders never work...

rgerman
Contributor

More problems with the script... looks like my rm command is throwing errors.

rgerman
Contributor

x

jamesdh
New Contributor

For anyone still following this or coming here via the Googles, I've gone ahead and added mysides to homebrew casks

Installing should be as easy as...

brew cask install mysides

Cheers!