Note to self: how to crosspost with images
Update
Hand-editing all the URLs (particularly when using Decap CMS to post, which I’m playing around with at the moment) is silly. We have computers for this kind of thing.
So my micropost JSON feed (which is what micro.blog looks at on this site) now uses an absolute-URLs filter on the post content. Just changed this:
"content_html": {{ post.content | jsonify }}
to this:
"content_html": {{ post.content | absolute_urls | jsonify }}
And I no longer have to worry about most of the details below.
The filter is trivial, and I’ve posted it as a gist.
TL;DR:
- Use full image URLs
- No title on the post
- Place the image in its own paragraph
I’m trying to be a bit more disciplined about posting micro-bloggy things with a POSSE mindset.
- Always better to own your own stuff
- I babble in various places these days, but none seems like The One Place We All Hang Out since Xitter became whatever the hell it’s become.
micro.blog is my tool of choice for this; any of my posts in the “microblog” category are picked up by micro.blog, reposted there, and cross-posted to Threads, Mastodon and Bluesky,
Unfortunately, I have a habit of getting this just-slightly wrong when I want to include a photo in the post.
The picture may show up on some platforms but not others; may be a broken link in some places; or may just quietly go missing from the post. Oh, and if I accidentally include a title, the cross-posts become links back to the original blog post, rather than the “native” posts they’re meant to be.
To save myself the annoying post/realize mistake/delete everywhere/edit/re-publish loop, I blasted out 9 different variations of what “a post with a picture” might look like. The most-resilient version is about what you’d expect1, as detailed in the list above.
So my post from earlier today, which rendered as a link in various locales:
---
layout: post
title: Last day
category: micropost
date: 2024-11-02T07:44:00.000Z
---
![me, standing in front of an early voting place][pic]
Last day of early voting here in Brevard County, FL. #TeamAva
[pic]: https://roub.net/images/IMG_7212.jpeg
(and that was after I remembered to make the URL absolute) should in fact have been:
---
layout: post
title: ""
category: micropost
date: 2024-11-02T07:44:00.000Z
---
![me, standing in front of an early voting place][pic]
Last day of early voting here in Brevard County, FL. #TeamAva
[pic]: https://roub.net/images/IMG_7212.jpeg
Or, in the parlance of my test posts: