Tag: bash

PHP test watcher for MacOS

I was successfully able to use my previous Laravel test watcher for a very long time, while I was on Linux. But now on Mac, it does not work, as mac does not support inotifywait. Mac does however support similar thing, called fswatch, install via Brew: brew install fswatch Howev…

Fix ANSI data in nvim execute

After migrating my dotfiles over to Mac M3 I stumbled into roadblock issue for my neovim setup. Every time I saved a PHP file, a lot of garbled data got prepended at the beginning of said file. If you remember so far back, my setup uses prettier for formatting everything, mostly …

Post checkout composer install hook

Sometimes when working on a PHP project where there are a lot of branches potentially sitting on incompatible packages, it can be a pain to always remember to manually run composer i or whatever docker alternative or alias one might be using. After forgetting, there are error mes…

Optimize many PDFs at once

I had to work with many scanned PDF documents that were saved in a very un-optimal way, each one having up to tens of MBs. This was not suitable for sending via email and also unnecessary. I saw an option on my girlfriend's Mac to optimize PDF. The result was that her document dr…

Issues restoring Gitea from dump

Somehow, the official documentation for restoring Gitea from dump did not work for me. Roughly, the following command for the original rootful Docker image could look like this: /app/gitea/gitea dump --file gitea-dump.zip -c /data/gitea/conf/app.ini --skip-lfs-data --skip-reposit…