powRSS
Home Recent Glimpses Shuffle Blogs Random

New: Explore conversations across blogs with powRSS Mentions

¬ just serendipity 🍀

Thiago Perrotta

Welcome to my digital garden – a space dedicated to exploring technology and sharing what I’ve been learning. This site reflects my passion for continuous learning and open-source software, wherein I document my journey, offer insights, and dive into miscellaneous topics that reflect my interest. My goal is to maintain a corner of the Web for self-expression focused on valuable, distraction-free content. I believe in the power of the Open Web as a platform for sharing knowledge.

August 2026

September 2026

October 2026

Top Words

  • claude
  • code
  • reply
  • github
  • commit
  • homebrew
  • script
  • shell
  • anki
  • update
  • atuin
  • pull

All posts (411)

Problem statement: Given a Terraform project full of pending changes (terraform plan), update its outputs only. I would expect to be able to use -target to do so, but that’s not possible. This flag is intended for resources only. The correct approach is terraform apply -refresh-only: Running terraform apply...
Previously. I couldn’t resist creating a pre-commit hook for this: repos: - repo: https://github.com/thiagowfx/pre-commit-hooks/ rev: v0.0.11 hooks: - id: check-bash-shebang types: - shell In action: % cd {pancake} % pre-commit run -a check-bash-shebang Check bash scripts use portable...
Previously. Problem statement: Given a password-protected .pdf file, remove its password. It’s indifferent whether the file gets overwritten or whether a new one is created. ghostscript can do it: gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=output.pdf -c .setpdfwrite -f input.pdf qpdf can do it: qpdf...
When writing portable shell scripts, should we prefer #!/bin/bash or #!/usr/bin/env bash? I tend to write #!/bin/bash by hand, but here is an argument to prefer the env version instead: thiago.perrotta@thiagoperrotta-MacBook-Pro ~ % /bin/bash --version GNU bash, version 3.2.57(1)-release (arm64-apple-darwin24)...
Problem statement: Given LLM keys shell environment variables: ANTHROPIC_API_KEY GEMINI_API_KEY OPENAI_API_KEY Export them only when they are needed. When are they needed? If I launch any one of these binaries: llm (generic) aider (generic) gemini (provider-specific: Google) codex (provider-specific: OpenAI) claude...
In English-speaking North America (Canada, USA) we refer to currency in the following ways: $50 fifty dollars 50 CAD, 50 USD – when necessary to disambiguate between Canadian and US dollars $50 CAD, $50 USD also works, but it’s less common A format that is non-existent: 50$. It feels wrong to place the dollar sign...
You write a long document. Perhaps it’s an ad, or a legal contract, or a design document. Problem statement: You would like to ensure, to a certain extent, that your audience has fully read it1. I like the following trick2: insert the following paragraph somewhere in the middle of the document: If you are reading...
The title is Claude Code’s favorite compliment to me. I’ve been slowly incorporating Claude Code as part of my daily workflow, as you can see below: Date Input Output Total Tokens Cost (USD) 2025-10-06 336 3,439 1,968,081 $1.33 2025-10-07 18,391 28,591 7,748,856 $5.32 2025-10-08 5,319 9,137 13,575,138 $9.74...
https://github.com/frnmst/md-toc: Automatically generate and add an accurate table of contents to markdown files. Adopting it via pre-commit in a git repository is very straightforward: .pre-commit-config.yaml: repos: - repo: https://github.com/frnmst/md-toc rev: 4a8b796dbde00f71eb1a51b075462f825f872c34 # frozen:...
Record Club: A {new,fun,better} way to discover and share music with friends. Record Club is a social music network that makes it easy to track, rate, review and compile lists of your favorite releases with a community of other music fans. I stumbled upon Record Club last week via a blog that I follow1. It is a...
Previously. I decided to add a new copy script to pancake to standardize copying command output and files to the system clipboard in both macOS and Linux. The idea was originally inspired by Evan Hahn: copy and pasta are simple wrappers around system clipboard managers, like pbcopy on macOS and xclip on Linux. I use...
It’s possible to do git patch -p to review diff hunks interactively, one by one. Can we accomplish something similar with git diff? If not, is there a tool that can accomplish that, in the same spirit of git patch -p, but with a read-only-centric workflow? The naïve approach is to simply run git patch -p and then...

Page 30 of 35