This short article is for all those working on Mac computers running OSX operating systems, and need to connect in a reliable way their Raspberry PI for a more comfortable development. I have tried and used this method for several different kind of developments with very good results.
It is possible to connect the Raspi to almost any PC through the networks (LAN or WiFi) using the popular protocols like SSH, SFTF (for data exchange), FTP etc. But the OSX has its own sharing method very efficient on the Mac computers that is the AFP protocol.So I simply searched if there is a way to install this protocol inside a Raspberry to reach some sort of file sharing with the Mac. I have found the very good blog post https://www.raspberrypi.org/forums/viewtopic.php?f=36&t=26826 (the article is also attached here as pdf document)
This simple tutorial explain how to install the Mac aft sharing protocol on the Raspberry PI but not only, it is interesting what I have discovered using it.
After the PI installation has been completed and the device rebooted at tis point it is visible and accessible from the Mac Finder. After you log to the PI exposed folders from your Mac as a matter of fact all the folders are available as stable mounts. This means that you can directly manage, edit and develop from the Mac on the Pi and immediately test and use what you have aded/changed on the Raspberry with zero effort. It is different than accessing to the PI via VNC and in my opinion it is better just for developing and not only. Below a short list of the environments I have used this approach connecting a Rapsberry PI3 to a Macbook pro running Sierra OSX
- Develop Python with the advanced and very complete IDE PyCharm, community edition
- Manage on the Mac the Raspberry PI Git repositories for the developed software using the GitHub desktop application
- Edit and review shell commands and other scripting text files with JEdit on Mac (but this is just one of my preferred editors)
- Backup and file transfer of the fiels from the Raspberry PI made easy
All these operations can be done easily and in a very comfortable way without involving the Raspcherry PI CPU and no extra storage.