Skip to content

Instantly share code, notes, and snippets.

View rivy's full-sized avatar
🏠
Working from home

Roy Ivy III rivy

🏠
Working from home
View GitHub Profile
@sefidel
sefidel / kagi.css
Last active April 11, 2024 16:57
Kagi Custom CSS. NOTE: Recent Kagi update has introduced a lot of unexpected breaking changes. I'm working on a fix.
/* Personal Tweaks */
.doggo-sit {
display: none;
}
/* Theme - Dark */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&display=swap');
.theme_dark {
--k-accent: #f16d43;
--k-accent-alt: #62a09d;
@joshellington
joshellington / kagi-darkmustard-theme.css
Last active April 28, 2024 15:54
A slightly refined, dark-focused, mobile-supported Kagi theme. Works best using Dark Theme, and either Moon Dark or Royal Blue.
:root {
--font-main: "Inter", system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
--font-lufga: "Inter", system-ui, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
}
.theme_dark, .theme_moon_dark, .theme_moon_dark_conditional {
--app-bg: #181715;
--page-text: #F2E6D7;
--primary: #F2E6D7;
@saidaspen
saidaspen / aoc.css
Last active May 20, 2023 21:23
AoC CSS
input ~ span:before,
.leaderboard-entry,
.privboard-row {
font-family: "Source Code Pro", monospace;
letter-spacing: 1px;
}
body * {
text-shadow: none !important;
}
@usayamadx
usayamadx / ExportKindle.js
Last active March 23, 2024 17:53 — forked from jkubecki/ExportKindle.js
Amazon Kindle Export
// init
let xhr = new XMLHttpRequest()
let domain = 'https://read.amazon.com/'
let items = []
let csvData = ""
// function
function getItemsList(paginationToken = null) {
let url = domain + 'kindle-library/search?query=&libraryType=BOOKS' + ( paginationToken ? '&paginationToken=' + paginationToken : '' ) + '&sortType=recency&querySize=50'
xhr.open('GET', url, false)
@ptc-mrucci
ptc-mrucci / unit.sh
Last active March 31, 2023 10:49 — forked from tvlooy/unit.sh
Bash test: get the directory of a script
#!/bin/bash
tmp=$(python -c "import os, sys; print(os.path.realpath('/tmp'))")
function test {
MESSAGE=$1
RECEIVED=$2
EXPECTED=$3
if [ "$RECEIVED" = "$EXPECTED" ]; then
@joepie91
joepie91 / es-modules-are-terrible-actually.md
Last active April 26, 2024 13:33
ES Modules are terrible, actually

ES Modules are terrible, actually

This post was adapted from an earlier Twitter thread.

It's incredible how many collective developer hours have been wasted on pushing through the turd that is ES Modules (often mistakenly called "ES6 Modules"). Causing a big ecosystem divide and massive tooling support issues, for... well, no reason, really. There are no actual advantages to it. At all.

It looks shiny and new and some libraries use it in their documentation without any explanation, so people assume that it's the new thing that must be used. And then I end up having to explain to them why, unlike CommonJS, it doesn't actually work everywhere yet, and may never do so. For example, you can't import ESM modules from a CommonJS file! (Update: I've released a module that works around this issue.)

And then there's Rollup, which apparently requires ESM to be u

@jimmychu0807
jimmychu0807 / string-conversion.rs
Created November 21, 2019 10:20
Conversion between String, str, Vec<u8>, Vec<char> in Rust
use std::str;
fn main() {
// -- FROM: vec of chars --
let src1: Vec<char> = vec!['j','{','"','i','m','m','y','"','}'];
// to String
let string1: String = src1.iter().collect::<String>();
// to str
let str1: &str = &src1.iter().collect::<String>();
// to vec of byte
@cerebrate
cerebrate / README.md
Last active December 2, 2023 08:17
Recompile your WSL2 kernel - support for snaps, apparmor, lxc, etc.

WARNING

THIS GIST IS EXTREMELY OBSOLETE. DO NOT FOLLOW THESE INSTRUCTIONS. SERIOUSLY.

IF YOU IGNORE THE ABOVE WARNING, YOU AGREE IN ADVANCE THAT YOU DIDN'T GET THESE INSTRUCTIONS FROM ME, THAT I WARNED YOU, AND THAT I RESERVE THE RIGHT TO POINT AND LAUGH MOCKINGLY IF AND WHEN SOMETHING BREAKS HORRIBLY.

I'll do a write-up of current custom-kernel procedures over on Random Bytes ( https://randombytes.substack.com/ ) one day soon.

NOTE

@fnky
fnky / ANSI.md
Last active May 3, 2024 17:31
ANSI Escape Codes

ANSI Escape Sequences

Standard escape codes are prefixed with Escape:

  • Ctrl-Key: ^[
  • Octal: \033
  • Unicode: \u001b
  • Hexadecimal: \x1B
  • Decimal: 27
@krisleech
krisleech / renew-gpgkey.md
Last active April 22, 2024 20:13
Renew Expired GPG key

Renew GPG key

Given that your key has expired.

$ gpg --list-keys
$ gpg --edit-key KEYID

Use the expire command to set a new expire date: