Archives

Tag: indieweb

  • iOS Shortcut Actions for Micropub posting


    I recently lamented about how few options there are for Micropub posting on iOS now that Indigenous was pulled from the app store. I had a hunch that the Shortcuts app could be a solution since Micropub takes pretty simple cURL requests, and after some testing to figure it out I put together a set of three Shortcuts to do the most popular Micropub actions. You can install them from the iCloud links:

    1. Like, Reply, Bookmark, or Repost a URL
    2. Post a Note
    3. Post a Note with an Image

    The first time you install one of these Shortcuts, you’ll be prompted to provide your Micropub endpoint and an IndieAuth token with the scope create profile update media.

    How do they work?

    They essentially take inputs (a URL or text) and make a curl POST request to your Micropub endpoint with a Bearer token that you provide on initial setup. Then it gives you the option to open up the URL for your post to take a look at it.

    The Like/Reply/Bookmark/Repost action has a bunch of conditionals to handle each action a little differently.

    The Post a Note with an Image action makes two separate curl requests: One to the Media endpoint for posting the image (which is automatically converted to a JPEG since most sites and browsers don’t support HEIF), the URL for which is then stored as a variable, then one to the regular endpoint with your note text and the image you wanted to post. I couldn’t actually get the “photo” parameter to work in the curl request, so I did it the old fashioned way and appended an HTML img tag to the “content” parameter. I also add a class micropub-img for easy styling. If anyone figures out how to get the photo parameter to work with the curl request, I’d be happy to update the action accordingly.

    Some screenshots

    The Like and Reply actions:

    Regular Note action:

    The Note with Image action:

    Videos of the Shortcuts in action

    Demonstrating the Like action on a URL:

    Demonstrating posting a regular Note from a Shortcut added to my Home Screen:

    Demonstrating posting an Image with a Note:

    Syndicated to IndieNews
  • My Indie Likes Workflow


    As part of trying to implement a website-first POSSE workflow, I wanted to start with posting Likes to my website and sending out webmentions from them. That is a lot of what I used to tweet out. Why should a record of what I like be stored elsewhere?

    It took me a little while to figure out what I wanted this system to look like, but once I landed on it and verified it could work with a couple quick tests, I got to work building it out and it has been running smoothly for a couple of weeks.

    Inputs and Outputs

    Where do I read content the most and how can I get links from there into my website? This was my research question before Christmas.

    When I’m at my computer, posting likes is fairly painless, though it is a multistep process:

    1. Go to my website
    2. Log in
    3. Click to add a new like
    4. Paste in the URL
    5. Add commentary
    6. Click publish

    There is more friction on mobile, which is where I tend to read a lot of content.

    Jan Boddez pointed out that using Micropub reduces that friction. Unfortunately I couldn’t find clients that reliably worked for me on iOS.

    So, that put me back in the realm of looking for solutions. I did what I do on most projects: Look where the inputs are coming from.

    • I spend most of my time reading articles on mobile.
    • 50% of what I want to post as Likes comes from content already in my RSS feed reader.
    • The rest come from a mix of social, email, general browsing (things like news.ycombinator.com, pinboard.in/popular), and Slack groups.

    Whatever I choose has to incorporate all of these channels and has to work from all of my devices (macOS, iOS, and iPadOS).

    I decided to handle likes coming from the various sources in two ways:

    1. A solution specifically for my RSS reader
    2. A solution for everything else

    From the RSS Reader

    My RSS reader of choice is NetNewsWire (I used it before the Black Pixel era too), and I use Feedbin as my feed syncing service (and the email -> RSS functionality).

    Feedbin and NetNewsWire supports stars, so I decided that anything I star in Feedbin should be posted as a Like on my site.

    Feedbin has an API that makes starred entries available in two ways:

    • As a filter option on the Entries endpoint
    • As its own endpoint that returns a list of IDs, which then need a follow-up API call to fetch the contents

    I thought about a couple ways of fetching those starred items and turning them into posts. What I landed on is a simple plugin that polls the API once an hour, posts new items as Likes, then saves the IDs of the posts it processed so they won’t be processed again.

    This was the first proper WordPress plugin I’ve build and I learned a lot in the process:

    • The proper way to set up and tear down dependencies on install and uninstall hooks.
    • Working with WP Cron.
    • Setting up plugin settings pages and saving options.

    The Likes are posted using Jan Boddez’s IndieBlocks plugin context block, which also handles sending out webmentions.

    Here is the plugin, free to use or remix:

    GitHub – cagrimmett/feedbin-stars-to-indie-likes: Takes starred posts from Feedbin and turns them into Indie Likes on a WordPress site
    Takes starred posts from Feedbin and turns them into Indie Likes on a WordPress site – GitHub – cagrimmett/feedbin-stars-to-indie-likes: Takes starred posts from Feedbin and turns them into Indie Likes on a WordPress site
    github.com

    If I were to remake this from scratch, I’d probably save the post permalinks instead of the post IDs to the database to check. That seems slightly more hardened, and also ensures I’m not posting duplicate Likes if a Feedbin ID ever changes.

    An improvement I’d like to make: Add a filter to load the plugin updates from GitHub instead of WP.org with the new Update URI header.

    Everything Else

    For everything else I decided to piggyback off of a bookmarking solution I use. Bookmarking is pretty fast and shared across all of my devices, so I set up a specific folder called Likes and any time something gets added to that folder it gets turned into a Like.

    I currently use Larder.io for my bookmarking, which supports making folder contents accessible via RSS. This is perfect for my use case: No authentication, just fetch a feed and parse it. WordPress was born for this.

    Side note: I change bookmarking apps as often as I change email apps. I’ve used Pocket, Instapaper, Raindrop, Evernote web clips, Notion, browser built-in options, etc. I know one day I’m going to migrate everything to Pinboard and then it will live there for the rest of my days. For now, I’m still using Larder.

    I made another plugin very similar to the Feedbin one above, except that it fetches and parses an RSS feed with WordPress’s built in fetch_feed function. Like the other plugin, it fetches new posts once an hour and posts new Likes, then saves the permalinks of the posts it processed to the database so it skips those next time.

    Since bookmarks can have a description, it optionally outputs a paragraph block after the Like with the description I created. Again it uses Jan Boddez’s IndieBlocks plugin context block.

    GitHub – cagrimmett/rss-to-indie-likes: WordPress plugin that takes posts from an RSS feed and turns them into Indie Likes on your site.
    WordPress plugin that takes posts from an RSS feed and turns them into Indie Likes on your site. – GitHub – cagrimmett/rss-to-indie-likes: WordPress plugin that takes posts from an RSS feed and turns them into Indie Likes on your site.
    github.com

    The main thing I learned working on this version is the default feed cache when you are using fetch_feed() in WordPress is 12 hours and you can override it with a hook: wp_feed_cache_transient_lifetime

    Both have been running on my website for a couple weeks now without a hitch. I’ve yet to link Likes and Notes in the nav or on the homepage because I want to redesign how they are output, but I linked them here if you are interested.

  • Week of January 9, 2023


    Whew, what a week. Charlie was pretty sick all week and stayed home from daycare. We think it was a combination of something resembling the flu and RSV from the symptoms, plus some teething thrown in there for good measure. He was miserable.

    For the first three days there was a lot of vomiting and fevers. We had to wash every towel and blanket in our house, most pillows, and some rugs. We each changed our outfits multiple times a day and took multiple showers. His nose was also a constant faucet, so anything that didn’t have puke on it had snot. Then came the constipation and coughing, and shortly after that the teething pain. He was lethargic most of the week. Days 4 and 5 were the worst. Thankfully his breathing remained good and we were able to keep fluids in him long enough for him to make diapers, so no need for urgent care.

    He wanted to be held 24/7 (and cried when we had to set him down), so Amanda and I switched off who help him and who slept or worked. It was like we reverted to the newborn days again. To top it off, Amanda and I both got sick too, but thankully not as sick as Charlie. Coughs, sore throats, and fatigue were the extent of it for us. COVID tests came back negative, so we don’t know what it was. It was certainly the most challenging parenting week we’ve had since he was a newborn. I am very thankful to have Amanda as my partner and that we are usually on the same page for how to handle tough situations like this and share the burden. I’m also thankful we have flexible jobs and work from home.

    Poor kid. We felt so bad for him.

    As of writing this on Saturday night, he is on the upswing. Eating more, less coughing, interested in playing again, and he slept in his own bed for a little bit.


    The night before Charlie got sick, we made fondue at home for dinner. It was a hit, but a consequence I hadn’t considered is that Charlie may refuse to eat anything for the foreseeable future if he can’t poke it with a fondue fork first 🫕 🤷‍♂️


    Charlie has been signing with us more to communicate what he wants, and it has been really gratifying to watch his face light up when we understand what he is signing and he gets his desired outcome.


    I helped a friend move on Saturday morning. I was pleasantly surprised that despite carrying heavy furniture down the stairs of a three floor walk up and the aforementioned tribulations of the week, I didn’t get fatigued or even out of breath.

    I’m reminded that it is nice to have a circle of friends who help each other.

    They were giving away an old soda siphon that doesn’t work, so I grabbed it on a whim. After some trial and error I finally got it apart to figure out what is wrong with it (the rubber gaskets are cracked and hard as rocks). So guess who is researching replacement parts for antique soda siphons?


    I’ve been testing out posting short-form content on this site first, then syndicating it out to Mastodon and Twitter. That stuff lives over at https://cagrimmett.com/notes for the time being. I’ll probably change the slug to micro or something. Or maybe I’ll rename my digital garden (current called notes.cagrimmet.com) instead, I haven’t decided.

    I have more work to do there because Twitter syndication isn’t working as well as I’d hoped and I don’t love how my theme is outputting the content, so I haven’t linked it in the navigation yet. I had hoped to work on it more this week, but, well, you know.

    Since Twitter APIs for third parties aren’t working for unknown reasons, I probably wouldn’t have made much progress on this front anyway.

    I’ve also been sending out web mentions for Likes that I post here at https://cagrimmett.com/likes/ (also not linked in the nav yet).


    I’m getting really into tiki recently. Moreso the drinks and less the faux-Polynesian pop-culture, though there is some of it that isn’t problematic. I’ve been searching out various styles of rums locally (see both Smuggler’s Cove categories and Minimalist Tiki categories), tracking down recipes, and mixing up fun concoctions at home.

    We also got a standalone pellet ice maker, which is a game changer. We’d definitely use it for more than cocktails, too. I’m envisioning lots of iced tea and coffee this summer.


    Who thought we’d be talking about gas stoves on social media this week?

    My take on gas stoves: I prefer them, but the emissions do give me pause with a baby in the house, so I have CO detectors on all floors and replaced my recirculating fan with an actual exhaust fan (which entailed cutting a hole in the side of my house to install a vent).

    One thing a lot of people miss is that you can still cook on gas when the power is out, which is becoming a more frequent occurrence recently. When the power was out for a week, it was really nice to be able to cook meals and heat water.

    I currently have no plans to replace my gas stove. If/when it is no longer working and more expensive to fix than replace, I’ll revisit the current evidence and reconsider.


    I’ve had a lot of time for reading books or listening to audiobooks this week, so I’ve been reading Blake Crouch’s Recursion and listening to more of book 5 of Neal Stephenson’s Baroque Cycle.

    For TV/movies, we watched a lot of Songs for Littles, various remakes of 101 Dalmatians, the 1992 animated Aladdin, and Animal Planet this week with the sick boy. Even when he is sick and lethargic, he loves animals. Zebras, giraffes, and dogs never fail to get his attention.


    At work I’ve been thinking a lot about payment platforms and migrating billing tokens for subscriptions with zero downtime and zero customer disruption (purchases and renewals still happening during the migration period). I also did some FTP dumpster diving on a site we recently started working with to resurrect some code that had gone missing, which was a success. Another week in the life of the Special Projects Team.


    Last week’s meal plan didn’t work out as expected. See above. I did make a couple of the meals (chicken soup, gyudon), but we ate a lot of leftovers and purchased meals from the freezer, so carrying over some of the plan from last week to this week. Some TBD here because Amanda will be traveling and what I cook will be somewhat dependent on how my work day goes and how Charlie is.

    • Sunday: Gnocci + sauce + arugula side salad with vinaigrette
    • Monday: Pork tenderloin with green beans and roasted potatoes
    • Tuesday: Chicken and pasta (garlic linguine?), side of roasted zucchini
    • Wednesday: TBD
    • Thursday: TBD
    • Friday: Dinner with friends, menu TBD
    • Saturday: Sheet pan dinner of some kind. Probably chicken thighs + some kind of vegetable. Side of cous cous?
    • Sunday: White bean soup with coconut milk?

    See you again next week. In the meantime, post some cool stuff on your own feed and send me the link. Also reach out to me if you are into tiki and want to chat, or if you have knowledge about antique soda siphons. 👋

  • Week of November 21


    This was a week of rest, recovery, and hanging out. Of course, it was Thanksgiving, but I also took Tuesday off to compensate for working last Saturday. I made some bread, renewed my passport online, and caught up on some much-needed household admin work.

    For Thanksgiving, it was only the three of us this year, but we had a nice relaxing day. I made a ham from Hemlock Hill Farm, homemade scalloped potatoes and rolls, and green bean casserole. Cranberry Galette for dessert. We sipped a scotch cocktail with cranberry syrup and oolong tea. Charlie spent the day going between playing outside in the leaves, helping in the kitchen, and playing in the living room. It was nice!

    Friday Amanda started cleaning out some stuff in the basement we wanted to get rid of, which we then dropped off at a second-hand store. We went to a birthday party for a 3 year old and connected with some new parent friends, got some coffee, ate leftovers, and played with Charlie.

    Saturday we went to IKEA to pick up a few things to help us turn part of one of the basement rooms into a play area for Charlie (the reason for Amanda’s clean-out!), then we went to some friends’ house for pizza, wine, and a toddler play date. I know I’ve said this before, but feels like we are getting more of a community here, which is nice.

    Sunday was more playroom clean up and assembly, grocery shopping, a trip to Home Depot, laundry, and getting ready for the week ahead. It is fun giving Charlie little jobs like putting screws from a disassembled bookshelf into a container, or wiping down the baseboards with a paper towel. He loves helping.

    Charlie has a new pre-bathtime ritual: Bringing us the Barnyard Dance book by Sandra Boynton and then pointing to the computer so we will play the song that goes along with it while he dances along. He loves it!

    Charlie is making his wants and interests more clear, which is great. He gets a thrill when we understand what he is communicating, and it is helpful to us to know what he wants. At the grocery store he made it clear that he’d like some raspberries and pretzels by getting very excited and pointing at them while we walked by.


    What do you call a gnome in the military?

    A nom de guerre.


    New infusion going: a ginger liqueur akin to Domaine de Canton. Ginger, vanilla bean, orange peel, sugar, water, and an aged rum.


    Every year around Thanksgiving I get a harebrained idea for a new project.

    This year the idea is to make a tool that will turn Jetpack likes into webmention-style likes as WordPress comments, kind of how brid.gy does for Twitter and Mastodon likes. The WordPress.com API exposing likes seems pretty straightforward and returns names, URLs, and avatars, which is all you really need for a Like comment with the Semantic Linkbacks plugin.

    I think this will be a one-time tool (you run it once to migrate, then turn off Jetpack Likes for posts) rather than a syncing tool. Probably something run with wp-cli. I need to look further into how the Semantic Linkbacks plugin is storing metadata in order to figure it out.

    Speaking of IndieWeb stuff, I’ve been on a mission recently. Yesterday I set up brid.gy to backfeed likes, shares, and comments from other platforms as webmentions, and I backfilled hundreds of comments on old posts. What a cool service. That brings my current state to:

    ✅ Sending and receiving webmentions
    ✅ Backfeeding mentions from other platforms via brid.gy
    ✅ Syndicating via RSS, JSON Feed, ActivityPub, and autoposting services
    ✅ Microformats and my representative h-card

    To do: Implement bookmarking + script a way to make that sync from other bookmarking services, set up short notes like tweets that originate on my site then get syndicated

    What else should I work on?


    I had some excitement on Twitter this week. I replied to a post by Archduke Eduard of Austria (one of the Habsburgs who used to be the royal family of the Austro-Hungarian Empire) where he said he was skeptical of “vox populi, vox dei.” I pointed out that we likely know the phrase from Alcuin, who said: “Nec audiendi qui solent dicere, Vox populi, vox Dei, quum tumultuositas vulgi semper insaniae proxima sit.” Translated: “And those people should not be listened to who keep saying the voice of the people is the voice of God, since the riotousness of the crowd is always very close to madness.”

    The exchange got hundreds of likes, RTs, and replies, including a couple from Eduard himself.


    Work win of the week: I suggested an improvement to Tumblr’s open graph tags to make tumblr blogs show up better on Twitter. The fix got shipped within a couple hours and improved Twitter sharing for everyone. Twexit!

    Speaking of, have you heard of the 1973 Scorsese mafia film Goncharov? It was so good. You should watch it if you haven’t.

    Archived Link
  • Migrate your Etsy Shop to your own website


    Etsy recently hit sellers with a 30% fee increase on sales, not including the processing fees, listing fees, platform store fee, and marketing fees (opt-in) they charge. They are taking quite a cut from indie sellers!

    They do provide a nice service and a built-in community. But indie sellers that have their own social following or email list can do better by moving to their own website.

    Moving to your own website may be a hassle, but is probably best for the long-term growth of your business. Right now you are at the mercy of Etsy’s fees and they have almost full control of your customers. Moving to your own domain and building out an email list puts you back in the driver’s seat:

    • You can build a direct relationship with your customers
    • You can choose a store software like WooCommerce that has a lower fees
      • And if you want to use a different store in the future, you can do so without disrupting sales – Users will keep going to the same domain and you can change how it works under the hood.
    • You can pick a layout that is more customized to your brand
    • You can offer more options like subscriptions, gift cards, custom option ordering, booking consultation sessions, etc

    I strongly recommend WooCommerce because it is open source, I work at the company that makes it, and I have lots of experience with it, but even if you move to Squarespace or Shopify with your own domain I’d be happy.

    With WooCommerce you’d need to pay for a domain, hosting, and credit card processing fees (2.9% + $0.30 USD per transaction). No sales, listing, or platform fees. WordPress and WooCommerce are free to download and use! There are some paid extensions you can buy to add functionality to your store, but those aren’t necessary to get your store set up and start making sales.

    If you want to go with WooCommerce, here is a checklist to get you started:

    1. Purchase a domain.
      1. I use hover.com, but feel fee to use whatever registrar you like!
    2. Purchase WordPress hosting and hook up your domain to it.
      1. Costs vary here, but I recommend using a managed host like Pressable, WPEngine, or Flywheel. Managed hosting is more expensive than shared hosting, but they take care of software upgrades, handle security, and generally have faster hosting. Budget shared hosting like GoDaddy or Bluehost can be alright, but will be more work for you long-term.
    3. Install WooCommerce and go through the setup process. WooCommerce Pay is a quick and easy option for a payment processor and is powered by Stripe on the backend.
    4. Pick a theme.
    5. Download your products from Etsy and use the built-in Import tool to bring them into WooCommerce.
    6. Set up your shipping rates.
    7. Set up your homepage and about/contact page.
    8. Sign up for a free MailPoet account and start collecting email addresses for your customers. Set up email automations if that is your thing.
      1. Rumor has it that you can download your customer email addresses with a bit of tech-based elbow grease. Perhaps once you have the email addresses, you can send them a one-time email about moving to your own site with a coupon code if they want to re-order, and an option to sign up for future updates.

    If you get stuck and need help, drop me an email. I don’t do freelance work anymore, but I’d be happy to give you guidance. I want more people to own their domains and keep the web independent!