Skip to content

Instantly share code, notes, and snippets.

View tombh's full-sized avatar

Thomas Buckley-Houston tombh

View GitHub Profile
@tombh
tombh / emoji.bash
Last active March 28, 2025 23:50
A homemade emoji picker
# Dependencies: `uni`, `wl-copy`, `kitty`, `wtype`, `fzf`
# `uni` project: https://github.com/source-foundry/uni
# Usage: `chmod a+x emoji.bash`, then run the script whenever you to pick emojis
export EMOJI_CHAR_PATH="/tmp/unicode_result-$USER.txt"
touch "$EMOJI_CHAR_PATH"
function _unicode_search {
local type=$1
const RESET: &str = "\x1b[m";
/// Print all the colours of the terminal to STDOUT.
fn print_native_palette() {
println!("╭─────────────────╮");
for y in 0u8..8 {
print!("│");
print_true_colour_full_bg(255, y, 0);
print_true_colour_full_bg(0, 0, 255);
for x in 0u8..15 {
@tombh
tombh / loud_cargo.toml
Last active February 16, 2025 19:40
Loudest Cargo 😱 How to setup Clippy to be as verbose as possible.
# Canonical lints for whole crate
#
# Official docs:
# https://doc.rust-lang.org/nightly/clippy/lints.html
# Useful app to lookup full details of individual lints:
# https://rust-lang.github.io/rust-clippy/master/index.html
#
# We set base lints to give the fullest, most pedantic feedback possible.
# Though we prefer that they are just warnings during development so that build-denial
# is only enforced in CI.
@tombh
tombh / ctl.sh
Created December 4, 2024 15:06
A lightweight BASH-only Make replacement
#!/usr/bin/env bash
# This is my personal approach to "Make" files (or `just`, etc).
#
# I put it in the root of a project and run it with: `./ctl.sh the_name_of_a_function`
# Where the function name is any function found in `./scripts/*.bash`.
set -e
export PROJECT_ROOT
Japanese, Hokkaido, Jingisukan
Japanese, Hokkaido, Rui-be
Japanese, Hokkaido, Hokkaido
Japanese, Tohoku region, Wanko soba
Japanese, Tohoku region, Morioka
Japanese, Tohoku region, Kiritanpo
Japanese, Tohoku region, Gy
Japanese, Chubu and Kanto regions, Inago no tsukudani
Japanese, Chubu and Kanto regions, Monjayaki
Japanese, Chubu and Kanto regions, Sushi
{
"nodes": [
{
"name": "Testing",
"contact": "[email protected]",
"locations": [
{
"type": "s3",
"bucket_name": "oam-uploader"
}

Keybase proof

I hereby claim:

  • I am tombh on github.
  • I am tombh (https://keybase.io/tombh) on keybase.
  • I have a public key whose fingerprint is 3317 BFD3 B392 2F6C 0DAE BE40 62CC 4ABB D9C0 B437

To claim this, I am signing this object:

These are some opiniated ideas for improvements to OAM/OIN. They are first of all straw men: merely ideas to stimulate conversation. My guiding principles here are the general software engineering best practices I've come to appreciate over the years. Therefore there is little here in terms of new features and little that an end-user would explicitly notice. They concern the health of the code: reduction of regression bugs, ease and confidence of refactoring, reduction of the learning curve for newcomers and contributors, scalability and browser performance.

These are of course good things in any circumstances. Though I have also borne in mind HOT's plans to promote and expand OAM beyond its current audience and vision.

Github Improvements

Contribution policies

  • Always rebase, rather than merge, by default on github. This makes the Git logs more readable.
  • PRs must include new/amended test cases.
  • master as the default branch, with staging and production reflecting increasing stability.
#! env ruby
loop do
begin
ping = `ping -n -c 1 -W 3 google.in 2>&1`
rescue
puts "Failed ping"
sleep 1
next
class ErrorHandler
def foo
potential_error
rescue StandardError
puts 'An error was handled'
end
end
RSpec.describe do
let(:instance) { ErrorHandler.new }