Skip to content

Instantly share code, notes, and snippets.

View amcolash's full-sized avatar

Andrew McOlash amcolash

View GitHub Profile
@amcolash
amcolash / yt-dial-scrubber.user.js
Last active October 21, 2026 17:44
Full Scroll Dial Scrubbing for YouTube (GreaseMonkey/TamperMonkey)
// ==UserScript==
// @name YouTube Dial Video Scrubber with HUD Preview (Adaptive Duration + Deadband)
// @namespace http://tampermonkey.net/
// @version 1.10
// @updateURL https://gist.github.com/amcolash/e03ebdde244d3a49da44273cb6b2f7b5/raw/177c8d6440a89491203067a36b397a35a773b55a/yt-dial-scrubber.user.js
// @downloadURL https://gist.github.com/amcolash/e03ebdde244d3a49da44273cb6b2f7b5/raw/177c8d6440a89491203067a36b397a35a773b55a/yt-dial-scrubber.user.js
// @description Smooth dial scrubbing with deadband anti-twitch filter, duration-scaled acceleration, and adaptive HUD
// @match https://www.youtube.com/*
// @noframes
// @grant none
@amcolash
amcolash / steam-deck-install.sh
Last active September 2, 2022 23:05
An install script to set up developer tools on steam deck
#!/bin/bash
### Steam Deck dev tools install script ###
# This script needs to be run as root
if [ "$EUID" -ne 0 ]
then echo "Please run this script as root (with sudo)"
exit
fi
@amcolash
amcolash / index.js
Created August 7, 2021 20:21
Tampermonkey script to copy colors from SchemeColor.com
// ==UserScript==
// @name SchemeColor.com Copy Button
// @namespace http://tampermonkey.net/
// @version 0.1
// @description copy color palette from SchemeColor
// @author Andrew McOlash
// @match https://www.schemecolor.com/*
// @icon https://www.google.com/s2/favicons?domain=schemecolor.com
// @grant GM_setClipboard
// ==/UserScript==
@amcolash
amcolash / convert.py
Last active August 23, 2026 10:56
Python script to convert images for "The World's Worst Video Card" by Ben Eater
from PIL import Image
import struct
# Options to set up
file = "iceland.jpg"
dither = True
showPreview = True
# Palette code based off of https://stackoverflow.com/a/29438149/2303432
@amcolash
amcolash / index.js
Last active July 25, 2020 19:16
Merge IP blocklists
/* Simple node script to merge 2 IP blocklists into a single one for use with Synology */
const fs = require('fs');
const path = require('path');
function makeSet(file) {
const split = file.split(/\r?\n/);
const set = new Set();
split.forEach(ip => set.add(ip));
@amcolash
amcolash / extend_tiles.sh
Last active June 11, 2020 07:20
Tile extension script (add padding to a tileset/spritesheet)
#!/bin/bash
# Add padding to a tileset. This script assumes that the input file is a png
# Usage: extend_tiles.sh [image_file.png] [width] [height] [new_width] [new_height] [columns]
# 1 2 3 4 5 6
if [ "$#" -ne 6 ]; then
echo Usage: extend_tiles.sh [image_file.png] [width] [height] [new_width] [new_height] [columns]
exit 1
fi
@amcolash
amcolash / Tuxedo InfinityBook.md
Last active October 15, 2024 03:15
Notes on how I set up my Tuxedo Infinity Book S 14 v5

Setting Up Tuxedo InfinityBook S 14 v5

Add Tuxedo Repo + Install Tuxedo Drivers/Utils

All of the Tuxedo stuff seems to be optional and this laptop has fantasic support out of the box w/ Xubuntu.

To add the repos, make a source list for the tuxedo repos sudo vim /etc/apt/sources.list.d/tuxedo-computers.list

Add the following (for now, until updated)

@amcolash
amcolash / flowkey.js
Last active August 7, 2023 14:50
UPDATE, see here: https://github.com/amcolash/flowkey-scraper - Noteflight auto transcribe
// Find the sheet music images on the page
const elements = document.getElementsByClassName('split-image');
// Check that there are actually images on the page
if (elements.length === 0) {
console.error('No images found');
} else {
// If images were found, extract the base url from the 1st one
const imageUrl = elements[0].src;
const imageIdMatch = /\/sheets\/([\w\d]+)\//;
@amcolash
amcolash / ATTiny + Micronucleus
Last active April 22, 2025 08:43
ATTiny85 + micronucleus using an AVR programmer
This gist is a list of instructions that I used to program my ATTiny85s with Micronucleus. They worked for me, but your mileage may vary! I would highly recommend starting by looking at the SparkFun article linked at the bottom for schematics and more in-depth info. This gist is mostly just a copy/paste list.
## Required:
- ATTiny85
- AVR programmer
- 1 uF capacitor
- Micronucleus FW: https://github.com/micronucleus/micronucleus/releases
- avrdude: http://www.nongnu.org/avrdude/
## Setup:
@amcolash
amcolash / scrape.js
Last active July 22, 2025 17:28
A tapermonkey script to scrape linkedin job listings
// ==UserScript==
// @name LinkedIn Scraper
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author Andrew McOlash
// @match https://www.linkedin.com/jobs/search/*
// @grant none
// ==/UserScript==