In Terminal, paste the following:
defaults write com.apple.finder AppleShowAllFiles YES
Press return
Hold the ‘Option/alt’ key, then right click on the Finder icon in the dock and click Relaunch.\
Show/Hide Hidden Files using Terminal Aliases
In Terminal, paste the following: sudo nano ~/.bash_profile or sudo nano ~/.zshrc
Enter your Mac’s administration password if required, then hit return
At the bottom of the open .bash_profile
file, paste the following:
alias showFiles='defaults write com.apple.finder AppleShowAllFiles YES; killall Finder /System/Library/CoreServices/Finder.app'
Below that, paste the following:
alias hideFiles='defaults write com.apple.finder AppleShowAllFiles NO; killall Finder /System/Library/CoreServices/Finder.app'
Press ctrl + O
and hit return to save the file
Press ctrl + X
to exit the file and return to the command line
In Terminal, paste the following: source ~/.bash_profile
or source ~/.zshrc
to refresh your profile and make the aliases available