Skip to content

Instantly share code, notes, and snippets.

View ctrlcctrlv's full-sized avatar
🛠️
happy hacking

Fredrick Brennan ctrlcctrlv

🛠️
happy hacking
View GitHub Profile
@ctrlcctrlv
ctrlcctrlv / alittlehebrew.hc.css
Created April 5, 2024 14:02
alittlehebrew.com high contrast stylesheet
* {
font-family: "FreeSerif", "Times New Roman", "Times", "TimesNewRoman", "Liberation Serif", "Noto Serif Hebrew", serif;
color: white;
}
header, body, .modal-body {
background-color: black;
}
textarea, select, input, .selection > *, .select2-results > *, .card, .card > * {
@ctrlcctrlv
ctrlcctrlv / rust-maintainer-perfectionism.md
Last active January 4, 2024 15:42
Rust maintainer perfectionism

Rust maintainer perfectionism, or, the tragedy of Alacritty

I did not submit this to Hacker News and did not intend that this post would have high circulation but have no real problem with it being there or with it having such. I have more recent comments below. This post is from January 2020 and predates the Modular Font Editor K (MFEK) project.

I have not worked on Rust projects in quite a while, and don't know if I ever will again. I feel many crate maintainers are way too perfectionist, for example, despite all the developer hours that went into this PR, it took the effort within years to be (halfway) merged.

There's always a reason not to merge, isn't there? It would be better done with a new nightly language feature, or the function signature should have a where clause, or the documentation is not perfect. There's always a new nit to pick in the world of Ru

@ctrlcctrlv
ctrlcctrlv / gcloud_translate.bash
Last active October 18, 2023 09:01
gcloud_translate.bash
#
# gcloud_translate() Fred util
# ★ gcloud_translate [source_language] [target_language]
#
# @mainfunc cloud_translate
BANNER=$(cat<<'BANNER'
_ _ _ _ _ _ _
__ _ ___| | ___ _ _ __| | | |_ _ __ __ _ _ __ ___| | __ _| |_ ___ | |__ __ _ ___| |__
/ _` |/ __| |/ _ \| | | |/ _` | | __| '__/ _` | '_ \/ __| |/ _` | __/ _ \ | '_ \ / _` / __| '_ \
| (_| | (__| | (_) | |_| | (_| | | |_| | | (_| | | | \__ \ | (_| | || __/_| |_) | (_| \__ \ | | |
@ctrlcctrlv
ctrlcctrlv / sqlite3.pl
Created October 17, 2023 19:13
sqlite3.pl
#!/usr/bin/perl
$0 =~ s@.*/@@;
sub usage {
my $usage = <<'END_USAGE';
_ _ _ _____ _
___ __ _| (_) |_ ___|___ / _ __ | |
/ __|/ _` | | | __/ _ \ |_ \ | '_ \| |
\__ \ (_| | | | || __/___) || |_) | |
|___/\__, |_|_|\__\___|____(_) .__/|_|
|_| |_|
@ctrlcctrlv
ctrlcctrlv / .gdbinit
Last active July 25, 2023 03:23
The VISUAL BELL tolls for you, Elon Musk (download all files. run `make run` which needs Xephyr, if u still use Xorg maybe will work w/o, just run a.out)
file a.out
set $count = 0
set pagination off
break _main
commands
set $count = $count + 1
printf "Loop iteration: %d\n", $count
print event
continue
end
@ctrlcctrlv
ctrlcctrlv / download_fiverr_inbox.sh
Created July 20, 2023 16:18
download_fiverr_inbox.sh — ymmv!
#!/bin/bash
# make cookies and csrf files
# call w/timestamp of most recent msg
URL="https://www.fiverr.com/inbox/contacts/$TARGET_USER/load_more"
FILE_COUNTER=0
function fetch_messages {
TIMESTAMP=$1
@ctrlcctrlv
ctrlcctrlv / HTMLEMAILPLZ.HTML
Created July 14, 2023 11:45
Email signature notice that I only send HTML email
<div style="max-width:50em;max-height:3em;border:1px solid
currentColor;overflow-y: scroll">
<p style="font-size:.7em;width:50%"><strong>Notice: In general,
unless a <tt>listserv</tt> requires it, I <u>only</u> send
HTML email. Please <u>do not</u> request plaintext personal
email from me without a very good reason to do so. I do this
as very few free software folks of any competence in our
community insist on it. HTML email:</strong></p>
<ul style="font-size:.7em;width:50%">
<li><strong>allows for certain W3C standard certain
Script started on 2023-05-30 00:02:18-04:00 [TERM="xterm-kitty" TTY="/dev/pts/5" COLUMNS="147" LINES="34"]
]0;fred@debutanuki:~/Workspace/aur/sensible-utils[?2004h[fred(B@デブ狸(B ~/Workspace/aur/sensible-utils(B]$ 78!mgitre reset --hard
[?2004l
HEAD is now at cdf78cb v0.0.19 pkgrel 2
]0;fred@debutanuki:~/Workspace/aur/sensible-utils[?2004h[fred(B@デブ狸(B ~/Workspace/aur/sensible-utils(B]$ 78git log
[?2004l
[?1h
commit cdf78cbbe13887338e9b7c7eebe61b18577f6efe (HEAD -> master, origin/master, origin/HEAD)
Author: Fredrick Brennan <copypaste@kittens.ph>
Date: Sat May 27 13:21:30 2023 -0400
@ctrlcctrlv
ctrlcctrlv / アメリカン・サイコ名刺交換会.ass
Created May 4, 2023 06:27
アメリカン・サイコ名刺交換会(日本語字幕)
[Script Info]
; Script generated by Aegisub 9573-makepkg-26a5f00c8
; http://www.aegisub.org/
ScriptType: v4.00+
PlayResX: 384
PlayResY: 288
ScaledBorderAndShadow: yes
YCbCr Matrix: TV.709
[Aegisub Project Garbage]
@ctrlcctrlv
ctrlcctrlv / .bashrc
Last active April 21, 2023 22:56
Audit user logins in Bash (honor system, although could easily be made more secure if the user doesn't have root)
#!/bin/bash
[[ $- == *i* ]] || return
[[ -f scripts/record_session.sh ]] && . scripts/record_session.sh