Creating A Blog-Specific Syncing App For My Personal Site

I’ve long dreamt of a blog that’s as simple to work with as editing text files and hitting save. Static Site Generators are neat, but they’re not what I want.

This site is the closest I’ve gotten.

My current setup lets me edit and draft posts on my phone in the writing app of my choice and quickly see it live.

The biggest benefit is proofreading my writing in its intended context (this site) while maintaining a quick and enjoyable editing experience from anywhere.

(Spoiler: there’s a custom SFTP app involved.)

Here’s how the process works:

The Blog Side: It’s PHP

My philosophy in building my personal site is No Build Steps.

This is a boring, hand-written, html site with php mixed in.

For posts, I have a directory of markdown files which get transformed on-the-fly via Parsedown.

posts/
├── blog/
│   └── creating-a-synb-app-for-this-blog.md
├── project1/
│   └── ...writeups of relevant projects
└── project2/
    └── ...and so on

Everything from that directory shows up on the posts page while project-specific writeups also show on the homepage.

Being a boring site on shared hosting, I’m reliant on the classic FTP publishing workflow. This isn’t a huge deal for me, but I do lose some of the benefits of a git-based workflow. Additionally, mobile editing is more complicated.

What If I Could Edit It Anywhere?

That’s the dream. I tried it in the past by syncing a dropbox folder to a VPS site, but I treat VPS plans like my hobbies: one day you stop paying, then they go away. Shared hosting feels forever(-ish). But that’s another blog post.

For this blog, I built a tiny SwiftUI app that syncs my remote directory to the app’s storage via the Files interface, which other apps can see.

It’s got one big button, hardcoded credentials, and two-way syncing dependent on date-last-modified and file hash comparisons.

Here it is on the left, along with the same file structure displayed in Files.app and IA Writer:

Three screenshots: my custom app, the iOS Files app, and IA Writer, all showing the same synced files and directories.
My syncing app ↔ Files.app ↔ IA Writer

It connects automatically when opened. This lets me create and edit content in Writer then push up to the server with one button. (Or, vice-versa if I’ve worked on things elsewhere.)

It’s an extra step, but it’s quick and it’s my extra step.

Does It Work?

Surprisingly well. IA Writer picks up changes fast. If I pull a change from the server, it’s nearly instant to see an updated version when I switch back over to Writer.

Here’s a demo of making an edit:

What I Like About This

It lets me write where I want to write.

For me, that’s been IA Writer for 10+ years now. I’m not sure if other writing apps let you work out of arbitrary Files directories, but Writer does.

I get to see the real thing quickly.

There’s nothing like seeing an end-result in its production live environment. You get see all the quirks of loading and viewing a website. By pushing it live, I get that on any device, without having to deal with local servers and the hassle of sharing them.

And for writing, reading posts on the site itself helps me edit and notice mistakes. Especially on a phone.

It’s hyper-tuned to my process.

There are other FTP apps out there, but they’re now also code editors, VPN clients, PDF editors, document scanners, and who-knows-what. (With subscription plans.) Most aren’t built for syncing between Files directories.

What’s Rough

I’m still reliant on manually uploading images from a computer.

This is fine. Every image and video on this site is manually edited, tweaked, and compressed. Those workflows aren’t possible for me on mobile.

This specific workflow doesn’t translate beyond mobile

The desktop version of Writer doesn’t let you work out of an arbitrary folder. That means that means I’m copy/pasting if I want to write there on a laptop. And I lose out on their syncing, so when I move back to a computer, I’m pulling from the server.

Thanks for reading.

👋

Written