Show hidden files on a Mac

Update: You can download an app (Funter) to do all the work for you.

PHP Melody includes several files beginning with a dot (e.g. .htaccess). If you’re using a Mac OS to upload the PHP Melody into your server, you’ll have to first make the .htaccess files visible in Finder or your FTP app.

To show hidden files, first open up the Terminal app. If you’ve never used this, it’s here:

Appli­cations → Utilities → Terminal

A quick note before you do anything: using Terminal without knowing what you’re doing can really screw up your computer. It’s not unsafe to do, you just have to be very careful not to type in any commands that you don’t intend to. As such make sure you’ve read the code below carefully and have typed it exactly as written! You have been warned.

Okay now, right after the dollar sign you can go ahead and type or paste in the code below, and press enter.

defaults write com.apple.finder AppleShowAllFiles TRUE

Nothing will happen yet, because you need to restart Finder for the changes to take effect. To do this, you can either press option+command+esc to open the Force Quit Appli­cations window, select Finder from the list and hit “Relaunch”, or simply type in the code below in the Terminal window, and again press enter.

killall Finder

If you typed those lines correctly, your desktop icons should disappear for just a second while Finder restarts and the code in your finder window will look like the image screenshot below.

Now any hidden files on the system should be visible. If you’re not seeing the file you expected, it’s possible that your FTP client is not configured to pull down those hidden files, so you may need to check those settings also. And remember, deleting any system files can break stuff on your computer—if you’re going to go through this process, make sure you’re only editing stuff you know is pertinent to your site, like the .htaccess file.

[Source]