mathiasbynens / dotfiles

:wrench: .files, including ~/.macos — sensible hacker defaults for macOS
https://mths.be/dotfiles
MIT License
30.04k stars 8.75k forks source link

Looking how to Toggle 'Use Stacks' on Desktop #900

Closed Drallas closed 4 years ago

Drallas commented 4 years ago

I'm new to this and look how to Toggle 'Use Stacks' or how to discover where it might be stored as a defaults setting?

kamui545 commented 4 years ago
defaults read > before.txt

# Toggle your setting...

defaults read > after.txt

# then show diff with your favourite tool
code --diff before.txt after.txt
Drallas commented 4 years ago

Thanks.. @kamui545 👍

The settings is :

Enable Use Stack on Desktop

defaults write com.apple.finder FXPreferredGroupBy -string "Kind" /usr/libexec/PlistBuddy -c "Set :DesktopViewSettings:GroupBy Kind" ~/Library/Preferences/com.apple.finder.plist /usr/libexec/PlistBuddy -c "Set :DesktopViewSettings:IconViewSettings:arrangeBy dateAdded" ~/Library/Preferences/com.apple.finder.plist