If you're looking to get posts from my blog here in the fediverse, I [think I've successfully] set up @caseylisscom to do exactly that.
For those asking about auto-posting to Mastodon, I added [ugly] code to my bespoke blog engine to make a Mastodon API call directly.
@caseyliss GitHub link or it didn’t happen
@rileytestut But you see the idea is *not* to remove all doubt I'm bad at writing code. 🙃
@caseyliss pssh I’d only question your skills if you posted *immaculate* code 😛 bad code makes the world go round!

@rileytestut You should see this [unrelated] shitheap I'm in the midst of writing right now.

(Turns out Swift's Decodable is 😗👌🏻... until you have a heterogenous array, and then it gets real ugly real fast.)

@caseyliss oooof I can relate 😅 Was doing something similar recently (serializing NSError + userInfo via Codable) and ended up using an enum to represent heterogenous userInfo values…but it’s very boilerplate-y and doesn’t support arbitrary types https://github.com/rileytestut/AltStore/blob/0eeee699148d639d3fa4f9a061ac80d7850e5c38/Shared/Server%20Protocol/CodableError.swift#L24

If only `AnyCodable` was a thing 🙃

AltStore/CodableError.swift at 0eeee699148d639d3fa4f9a061ac80d7850e5c38 · rileytestut/AltStore

AltStore is an alternative app store for non-jailbroken iOS devices. - AltStore/CodableError.swift at 0eeee699148d639d3fa4f9a061ac80d7850e5c38 · rileytestut/AltStore

GitHub

@rileytestut @caseyliss Funny you should say that! There is an “AnyCodable” library here. I think most apps I’ve built use it, via OpenAPI Generator.

https://github.com/Flight-School/AnyCodable

GitHub - Flight-School/AnyCodable: Type-erased wrappers for Encodable, Decodable, and Codable values

Type-erased wrappers for Encodable, Decodable, and Codable values - GitHub - Flight-School/AnyCodable: Type-erased wrappers for Encodable, Decodable, and Codable values

GitHub