My favorite sudo command for Mac OS X Mavericks

In Mac OS X Mavericks, Use as Defaults is supposed to carry over to all newly opened Finder windows, but it doesn’t change any previously opened windows. If you want to revert all previously opened windows to that view, follow these steps:

Launch Terminal, copy and paste this command into the window that pops up, and hit the return key:

sudo find / -name ".DS_Store" -exec rm {} \;

At the password prompt, enter your admin password and hit the return key. When the default prompt, usually the $ sign, pops up again, quit Terminal, restart, open a Finder window, set it up the way you want, and click on Use as Defaults button. All subsequently opened or created folders should retain that view.