Craft CMS directory permissions when working locally on a Mac

I doubt this is specific to Craft CMS, but I'd been having problems with permissions when working on both Windows and Mac machines using the same files (synced using Dropbox). Use the Mac terminal to navigate to the project folder by dragging the folder into Terminal. Then CHMOD like so:

chmod -R 777 craft/storage

I found I also had to do the same with the folder I use for uploading images in Craft CMS

chmod -R 777 img/uploads

Thanks to Brad Bell at Pixel & Tonic for this one (link).