¬ 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.
July 2026
August 2026
September 2026
Top Words
- claude
- code
- reply
- github
- script
- homebrew
- commit
- shell
- atuin
- update
All posts (395)
terraformer: CLI tool to generate terraform files from existing infrastructure (reverse Terraform). Infrastructure to Code In other words: “reverse terraform”. I was quite excited to add this project to my tool belt, as it can save a lot of time with scaffolding and terraform import commands. Then Claude Code, once...
Problem statement: Make Google’s Gemini read CLAUDE.md and/or AGENTS.md. By default, it reads only GEMINI.md. Update ~/.gemini/settings.json to either: { "contextFileName": "AGENTS.md" } or { "contextFileName": "CLAUDE.md" } My config: { "contextFileName": "CLAUDE.md", "security": { "auth": { "selectedType":...
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...
Page 34 of 40