Skip to content

Instantly share code, notes, and snippets.

View extratone's full-sized avatar
🗿
sudo exit

David Blue extratone

🗿
sudo exit
View GitHub Profile
\documentclass[sigconf,anonymous=$anonymous$]{acmart}
\usepackage{booktabs}
\usepackage{caption} % http://mirror.easyname.at/ctan/macros/latex/contrib/caption/caption-eng.pdf
\usepackage{balance} % balancing bibstyles as per request in accepted submission
\usepackage{graphicx}
% We will generate all images so they have a width \maxwidth. This means
% that they will get their normal width if they fit onto the page, but
% are scaled down if they would overflow the margins.
@stephanbogner
stephanbogner / example.html
Last active December 28, 2022 08:45
Extract hex color codes from a string (e.g. text, SVG, HTML, XML) using a regex in JS
<script type="text/javascript">
let testString = ''
testString += '<div style="color: #00A9F8"></div><div style="color: #12345"></div>';
testString += '<div style="color: 00A9F8"></div><div style="color: #123456"></div>';
testString += '<div style="color: #fff"></div><div style="color: #000"></div>';
let regularExpression = /#(?:[0-9a-fA-F]{3}){1,2}/g // btw: this is the same as writing RegExp(/#(?:[0-9a-fA-F]{3}){1,2}/, 'g')
let extractedHexCodes = testString.match(regularExpression);
if ((/^localhost/).test(document.location.host)) {
var linkChecker = (function() {
"use strict";
let links, errors = [], completed = [], errorCounter = 0;
function addStyle(styleString) {
const style = document.createElement("style");
style.textContent = styleString;
document.head.append(style);
}
@brucebentley
brucebentley / iOS Shortcuts Catalog.md
Last active April 13, 2025 02:16
This is a public resource designed to help people get started with Siri Shortcuts & the Shortcuts app. It’s made up of the Shortcuts Library, a collection of over 125+ shortcuts grouped into folders, and the Action Directory, a documentation of 125+ of the actions in the Shortcuts app used to build shortcuts.

Bruce's iOS Shortcut Catalog

Hello and welcome to my Shortcuts Catalog!

This is a public resource designed to help people get started with Siri Shortcuts and the Shortcuts app.

It’s made up of the Shortcuts Library, a collection of over 125+ shortcuts grouped into folders, and the Action Directory, a documentation of 125+ of the actions in the Shortcuts app used to build shortcuts.

Enjoy!

@blacksector
blacksector / random-quote.js
Last active June 28, 2024 01:15
Pulls quotes from an API and displays it on a simple background
const QUOTES_API = 'https://quotes-api.netlify.app/.netlify/functions/get-quote';
const BG_COLOR = "#000000";
const BG_IMAGE = true;
let randomQuote = await loadQuote()
let img = null;
// no-background.js is needed from here if BG_IMAGE is set to true
// https://github.com/supermamon/scriptable-no-background
@LanceMcCarthy
LanceMcCarthy / UltimateListIds.md
Last active April 4, 2025 10:35
List of Package Ids
Name Package Id Version Source
7Zip 7zip.7zip 19.0.0 winget
Altap Salamander salamander choco
Alt-Tab Terminator alt-tab-terminator choco
AutoHotkey Lexikos.AutoHotkey 1.1.33.02 winget
AutoHotkey Store Edition HaukeGtze.AutoHotkeypoweredbyweatherlights.com Latest msstore (via winget)
Carnac
@palmin
palmin / .shellfishrc
Last active September 25, 2022 07:54
# include this from .bashrc, .zshrc or
# another shell startup file
# this script does nothing outside ShellFish
if [ "$LC_TERMINAL" = "ShellFish" ]; then
printURIComponent() {
awk 'BEGIN {while (y++ < 125) z[sprintf("%c", y)] = y
    while (y = substr(ARGV[1], ++j, 1))
    q = y ~ /[a-zA-Z0-9]/ ? q y : q sprintf("%%%02X", z[y])
    printf("%s", q)}' "$1"
@atnbueno
atnbueno / iphone-colors.css
Created November 29, 2020 16:21
Official iPhone colors according to apple.com/iphone/compare/ (also leather and silicone case colors)
/* basic colors */
.black { color: #2e3034 }
.gold { color: #e3ccb4 }
.jetblack { color: #000000 }
.rosegold { color: #ecc6c1 }
.silver { color: #e2e3e4 }
.spaceblack { color: #1c1d1e }
.spacegray { color: #b1b2b7 }
@kernoeb
kernoeb / docsify-markdown2pdf.sh
Created November 16, 2020 15:23
Build a PDF file from Docsify structure (markdown)
# Install deps
# sudo apt-get install -y texlive-latex-base texlive-fonts-recommended texlive-fonts-extra texlive-latex-extra
# sudo apt-get install -y texlive-xetex
# sudo apt install -y ghostscript
# wget https://github.com/jgm/pandoc/releases/download/2.9.2.1/pandoc-2.9.2.1-1-amd64.deb
# sudo apt install -y ./pandoc-2.9.2.1-1-amd64.deb
# rm ./pandoc-2.9.2.1-1-amd64.deb
#cp fonts/*.ttf ~/.fonts # I use Google Fonts (Roboto -> please see line 8)
cd book # directory where markdown files can be found