The Tower of Babel screwed all of us. i18n is more complicated than it should be for something that everyone deals with.
Installing SVN
The latest versions of xcode no longer includes SVN, so if you’re installing it fresh, you’re out of luck.
Running brew install svn installed it, but was giving me a Symbol not found: _apr_crypto_block_cleanup error.
I was able to fix that by running brew reinstall apr-util
Now I’m back to the early 2000s!
Bulk Remove Labels
gh pr list --label "[Status] Needs Review" --state closed --json number -L 350| jq '.[].number' | xargs -L 1 gh pr edit --remove-label "[Status] Needs Review"
We usually have an automation that removes some labels from a PR once it is merged. I haven’t looked into why that happened, but wanted to bulk remove it without having to use the UI.
This uses the gh cli command, installed via brew install gh on OS X and jq command, installed via brew install jq
First, it requests a list of PRs with the given label, that are closed, outputted in JSON with just the PR number with a limit of up to 350 issues (we had like 330 that were missed).
That pipes it to jq which parses out, in this case, the number field from every json object.
That’s piped to xargs which takes one line per execution and passes it to gh‘s pr edit command to remove that specific label.
Make Links Not Clickable in CSS
isset
isset( $a ) && isset( $b ) === isset( $a, $b )
Delete a Site on Let’s Encrypt
I so rarely need to delete a site off of my server that I forget how to tell Certbot not to care about a domain anymore. It’s silly easy.
sudo certbot delete
or if you want to get fancy:
sudo certbot delete -d example.com