The previous posts covered building this site on Cloudflare Workers and adding a custom domain. The natural next question was: can I publish a new post from my phone without a laptop nearby?
The answer turned out to be yes — and the solution required zero new tools.
The Problem with Traditional Workflows
Most static site generators assume you have a terminal open. You write the post, run a build command, deploy, commit the artifacts. Even with CI, you typically need to at least run something locally before pushing.
I wanted the opposite: write a Markdown file, add an image, open a pull request, merge it — and have everything else happen automatically. From anywhere, including a phone.
What the Pipeline Does
When a PR with changes to posts/** or images/** is merged to main, the CI pipeline runs npm run publish, which does four things in sequence:
- Reads the new post files from
posts/and parses their frontmatter - Compresses the hero images from any format (PNG, JPG, WebP) to WebP at 80% quality, max 1200px wide — a 5MB PNG becomes ~100KB
- Uploads the compressed images to Cloudflare R2 and deletes the originals from the repo
- Rebuilds
kv-seed.jsonand seeds Cloudflare KV with the updated post index and content
After that, a bot commits the generated artifacts (kv-seed.json, updated frontmatter with image: true) back to main with [skip ci] to avoid an infinite loop.
The worker picks up the new KV data on the next request — no deployment needed. Posts go live within 30 seconds of merge.
The Mobile Workflow
With this pipeline in place, publishing from a phone looks like this:
- Write the post — in the GitHub mobile app, create a new file at
posts/my-post.mddirectly in a branch - Add the image — upload the hero image to
images/my-post.jpgin the same branch - Open a PR — GitHub mobile handles this natively
- Merge — one tap, CI takes over
No terminal. No SSH. No laptop. The entire publishing flow fits in a phone screen.
The Manual Trigger
For cases where you want to re-run the pipeline without a new commit — re-seeding KV after a manual edit, re-deploying the worker, testing the pipeline — I added workflow_dispatch to the CI configuration:
yamlon:
push:
branches:
- main
paths:
- "posts/**"
- "images/**"
- "src/**"
- "scripts/**"
- "static/**"
workflow_dispatch:
This adds a "Run workflow" button in the GitHub Actions tab, accessible from the GitHub mobile app. One tap to trigger the full pipeline manually.
Assisted Publishing with Claude
The workflow I actually use most often goes one step further: I don't write the posts manually either.
- Open a Claude Code session from the web or mobile
- Describe the topic — Claude writes both the English and Spanish versions
- Upload the hero images to Google Drive
- Tell Claude the images are ready — it downloads them via the Drive API, commits posts and images to a branch, and merges the PR
- CI handles everything else
The entire flow from "I want to write about X" to "post is live" takes about 10 minutes and requires no local setup.
The Underlying Insight
The key realization is that CI pipelines are not just for deploying code — they can be the runtime for any automated task. Image compression, content processing, cache invalidation, artifact generation: all of this can live in a pipeline triggered by a git push.
Once the pipeline exists, the publishing interface becomes anything that can make a commit. A terminal, a phone, a web editor, an AI agent — it doesn't matter. The pipeline handles the rest.
That flexibility is worth more than any publishing UI.