Show Hidden Library and User Library files and folder in MacOS

If the /Library and ~/Library are hidden from the Finder – to show these directories in the GUI, launch Terminal from Applications/Utilities and run the command below with sudo and enter your admin password when requested:

sudo chflags nohidden /Library/ ~/Library/

to hide again:

sudo chflags hidden /Library/ ~/Library/

You can apply this to any directories in the filing system – so to see the hidden contents of the private folder including /etc you would apply:

sudo chflags nohidden /private

But you cannot hide/show defined invisible files/folders that are preceded by a “.” with chflags

To show all hidden files and folders, that start with a ‘.’ , back to Terminal in OSX 10.9 Mavericks:

defaults write com.apple.finder AppleShowAllFiles -boolean true ; killall Finder

Getting back to cleanliness:

defaults write com.apple.finder AppleShowAllFiles -boolean false ; killall Finder

 

To show all hidden files and folders, that start with a ‘.’ , back to Terminal for earlier versions of OSX 10.8 and prior:

defaults write com.apple.finder AppleShowAllFiles TRUE ; killall Finder

Getting back to cleanliness:

defaults write com.apple.finder AppleShowAllFiles FALSE ; killall Finder