Edit home assistant files form MAC

Ok I’m tired of VI. I want a visual editor that I can see colors in to better distinguish between comments and actual code. What’s the best way to accomplish this, Samba, Something else? Inquiring minds want to know. :slight_smile:

If you use VIM instead of VI you should have the desired results. If you are looking more for a desktop client, Atom is pretty solid and has a yaml plugin. I also recommend Text Wrangler. You could mount drive from the HA server and edit directly, but I prefer to keep local versions that I edit then sync when needed.

I am definitely not a Mac guy, but back when I toyed with OSX, TextMate was the editor I found most comfortable. This would run natively on your Mac, so you would need a way to move the files back and forth. Not being an Apple guy, I hesitate to make a suggestion here. I’m pretty sure there is an OSX build for Samba. You could use scp in a terminal, as well.

If you are currently using vi, and want another terminal based editor, nano ships with most linux distros these days (including raspbian and hassbian). Both support syntax highlighting.

Vim is also a solid suggestion, if you’re already used to vi. (It doesn’t come by default on raspbian, but you can easily install it with sudo apt-get install vim)

1 Like

I set up samba on the PI. On my mac I open finder, browse to the files I want to edit, then use text wrangler to edit them. A quick save, and reboot and done. I followed @bruhautomation excellent guide on setting up HA on a pi. In his guide he covers all the settings for setting up samba shares on the PI.

What I find works the best on the Mac is Sublime text 3 and there is a plug-in as well to browse via SSH. The files are pulled and uploaded in the background via Sublime Text3. There is a YAML syntax included inside of sublime. If you are brave you can install Cloud9 on your pi and access all your files from a web browser it works great as well I like that way changes made on a different computer will be able to be seen anywhere.


That’s actually where I am right now. But VIM is still VI with all it’s quirks.

For now I am going the route that MoridinTX suggested. It seemed the most straight forward and text wrangler was free at the app store. So far so good. I had a few issues with rights, but I straightened those out right. I’m afraid to do a reboot and see if changing rights around broke HA or AD somehow :frowning: :slight_smile: But for now, being able to easily distinguish comments from code is wonderful. Some of the stuff I have “borrowed” is very heavily commented and it just gets in the way. I wish python had a true block comment. I understand the tripple "'s do the trick, but then the code you commented out shows up in any documentation you generate. But then again who generates documentation. LOL

So I guess for now (until tomorrow at least), I am happy.

1 Like

I use Atom when editing from my Mac to my Ubuntu HA install via AFP. It’s a lightweight client, and it has plugins.

There’s an external webapp (website with text editor that does syntax highlighting) that can run in parallel to HASS, which, depending on your setup, you can embed into the HASS UI using the panel_iframe component. In that case it wouldn’t make any difference which OS you are using since it’s done via browser.

Here’s the repo: HASS-PoC-Configurator

@danichispa – Atom is nice, customizable, and quite powerful. It’s fantastic that it’s open source, however, it’s definitely far from being lightweight. :smiley:

You may or may not find this useful, but I put together a shell script that I use to manage my Home Assistant from any of my Macs (or any POSIX OS with BASH).

I built it for my personal use, but essentially you would just need to set the Variables to your settings and setup shared SSH keys.


  • All HA configs are stored on Dropbox (doesn’t have to be but I like the versioning and access to it from any machine).
  • Edit locally with Atom
  • When I select the deploy HA configs option it creates a tar file of the current configs and moves it to my local Mac in a backup folder (in Dropbox). That way I always have a backup before it pushes out any changes.
  • Syncs updated files
  • Verifies config

Nothing fancy but it does the job.

Thanks I like your solution! Nice! Don’t mind if I use that one myself. :smirk:

do you have a link to the guide you mentioned from @bruhautomation?

This is an older video from BRUH, it should work for the AIO installer.