Taskfile bash completion in homebrew

A tip for anyone using Taskfile and Homebrew on macOS. Actually this is more of a note to self, because I didn’t pay attention to this earlier.

Homebrew has two versions of bash-completion: bash-completion and bash-completion@2. The former is meant for bash 3.x and the latter is for bash 4+.

Normally it hasn’t mattered to me till now, because most formulas set up compatible completion scripts.

But it seems Taskfile’s completion script is only compatible with bash-completion@2.

Using an SSH jump host for Ansible

I was working from outside home today, trying to push out changes to a bunch of my homelab servers. As usual I was using Ansible, but I was connected over tailscale to the home network.

Now normally I would just create a socks/http proxy to one of my home machines and set the proxy environment variable like HTTP_PROXY and most apps would just work. But Ansible doesn’t seem to respect that environment variable.

There is an environment keyword that lets you set http_proxy variables, but that is for tasks executing remotely. They can use that environment variable for commands they are executing which need to call over the Internet. But what we need is a way to reach the target host in the first place.

AI running out of original human generated content

The AI gold rush is hitting a ‘bottleneck’ that could spell disaster for Google and Meta

A new study released Thursday by research group Epoch AI projects that tech companies will exhaust the supply of publicly available training data for AI language models by roughly the turn of the decade—sometime between 2026 and 2032. …

In the longer term, there won’t be enough new blogs, news articles and social media commentary to sustain the current trajectory of AI development, putting pressure on companies to tap into sensitive data now considered private—such as emails or text messages—or relying on less-reliable “synthetic data” spit out by the chatbots themselves.

As more and more slop keeps getting churned out on the internet and floods our search results, there is little and little incentive anyway for humans to generate content in the first place. This data doom feels like a self-fulfilling prophecy.

Using the code cli in VS Code Remote extension

VS Code (Dall-e generated)

One of the major reasons I switched to VS Code completely some years back is its excellent extension system, in particular the seamless remote SSH editing extension.

Remote SSH extension is really cool!

Using a local editor on a remote filesystem without fiddling with sshfs or the like, managing to use extensions like Python, Go and Copilot, all setup and configured locally but running on content on a remote system has been pretty cool. It helps me keep my office and personal content separate - I edit my personal codebase on my personal computers using vscode on my office laptop when I need to.

The annoyance about the code cli

But one of the most annoying thing while using the VS Code remote ssh extension was the VS Code cli, which I use a lot. I spend a lot of time on the terminal inside VS Code, and sometimes it is just easier to open a file from the command line using code FILE instead of reaching for the mouse to click on the file in the explorer.

Here is where it gets tricky.

If you have a VS Code installation on the remote computer, and you used it to install the CLI, that CLI executable (On Mac installed in /usr/local/bin/code ) will always open files in that local VS Code installation. It will not open the file in the remote SSH VS Code workspace that you have open.

TLDR: Use the script at the end of this post instead of the code cli in path if you want to open files in the remote ssh extension workspace.

Using Giscus for commenting on this blog

An online article (Dall-E 3)

I had removed disqus comments from my blog a few years back when I noticed the horrible privacy issues with Disqus.

But I always felt that I was missing out on some feedback I had received from visitors in the past, especially when I would benefit from correcting my mistakes.

Age encryption cookbook

Many locks for one secret

One of the niftiest tools that I have been using a lot nowadays is the deceptively simple encryption/decryption command line tool called age by Filippo Valsorda.

Encrypting secrets using keypairs instead of a single passphrase is obviously a more secure option, as it separates the concerns for encryption and decryption. Therefore you can share around the public key without fear for others to encrypt data for you that only you can decrypt.

Traditionally, we have been using tools like gpg e.g. while using eyaml in Puppet, etc. However, gpg comes with its own overhead of key management - multiple keyrings, tool configuration, etc. which makes the use case of simple encryption to be fairly complicated.

age packs a lot of functionality into its dead simple CLI interface - a single file to “manage” the keypair. It requires zero configuration. More importantly, it supports not just its own X25519-based key pair format, but it can even use SSH key pairs for encryption. For simple use cases, it even supports symmetric passphrases.

I have been keeping this document in my PKM for a while, and I thought it best to share in public as a cookbook as well.

Decrypting and concatenating PDFs with qpdf

qpdf docs

I wanted to quickly jot down some of the PDF tasks that the wonderful qpdf has been helping me do. This ranges from merging multiple PDF files to storing decrypted versions of annoying PDFs sent by some banks.

I used to use pdftk till some time back, but it had a lot of dependencies which were a pain to install. I exclusively use qpdf now instead.

Publishing helm charts on Artifacthub

artifacthub

As part of my journey in learning Kubernetes this year, I ventured today in pushing my first tiny helm chart to Artifacthub.

I had been using custom made charts for a couple of months now, but mostly in the CI/CD environment of my company. Packaging a chart for public consumption needed me to learn a few more things.

Disabling comments and Google Analytics

So, after ~20 years of maintaining this blog, I decided to disable comments entirely on the posts here. And turning off Google Analytics.

This was primarily driven by a recent privacy test I did on the blog, and to my utter shock, almost a dozen different websites seem to be contacted with every page load. I generally expected Google (for the analytics) and Disqus (for the comments) to be the websites figuring out here, so I felt absolutely betrayed by the bunch of other websites they call under the hood.