API v3 doc to understand the fields in .github/config/branch-protection/
: https://docs.github.com/en/rest/branches/branch-protection#update-branch-protection--parameters
Example script using it to temporarily disable branch protection rules for a single git push
:
#!/bin/bash
set -o errexit
# Prerequisite: gh repo-config init must be called to initialized JSON config files
config_dir=.github/config/branch-protection
# Backup current configuration:
cp $config_dir/main.json .
# Disable branch protection rules:
yq -iP -o json .required_pull_request_reviews=null $config_dir/main.json
yq -iP -o json .required_status_checks.checks=[] $config_dir/main.json
gh repo-config apply
# Push commit(s):
git push
# Restore initial configuration
mv main.json $config_dir/
gh repo-config apply
⚠️ Currently gh repo-config init
does NOT reflect your current repo settings when initializing files in .github/config/branch-protection/
, cf. issue 159
⚠️ Calling gh repo-config apply
will NOT preserve your current repo settings
For the past few months, I’ve had a bit of a background project going to ensure that my cloud-hosted personal data is safely archived on my own, self-hosted hardware, just in case. Google services are nice 'n' all, but I’m not 100% happy trusting them with everything in the long run.
Part of this project has been to archive my old email collection from GMail, which dates back to the initial public beta in 2004(ish?) -- and make it searchable, because what’s the point in having all that email if you can’t find the needle in the 20-year haystack when you need it?
Enter “notmuch” -- a “fast, global-search and tag-based email system”, which runs as a set of UNIX CLI commands, and is inspired by Sup, a mailreader I used previously.
webhint helps you improve your site's accessibility, speed, cross-browser compatibility, and more by checking your code for best practices and common errors.
Available as:
- VS Code extension
- browser extension
- CLI program
tl;dr:
sudo apt install tor
torify curl ...
An open-source guide to help you write better command-line programs, taking traditional UNIX principles and updating them for the modern day.
A useful script to work offline, in the train, to run in a local git clone of the target repository :
gh issue list --limit 100 --json number --jq .[].number | while read nb; do
gh issue view $nb > $nb.md
gh issue view $nb --comments >> $nb.md
done
Script to install Datalogics PDF Checker CLI on a Linux system:
curl https://raw.githubusercontent.com/Lucas-C/dotfiles_and_notes/master/bin/install-pdfchecker.sh | bash
PDF_Checker/pdfchecker --profile PDF_Checker/CheckerProfiles/everything.json --input $pdf
Lighthouse is an open-source, automated tool for improving the quality of web pages. You can run it against any web page, public or requiring authentication. It has audits for performance, accessibility, progressive web apps, and more.
You can run Lighthouse in Chrome DevTools, from the command line, or as a Node module.
Source code of the rules used
A vault for securely storing and accessing AWS credentials in development environments