Skip to content

Instantly share code, notes, and snippets.

View coverprice's full-sized avatar

James Russell coverprice

View GitHub Profile
@coverprice
coverprice / similar_names.py
Created August 25, 2019 20:47
Similar artist names
#!/bin/env python3
import json
from Levenshtein import distance
import unidecode
import re
from pprint import pprint
ARTISTS = {} # '<normalized name>': set(<variations>)
@coverprice
coverprice / extract_audio.ps1
Created May 21, 2022 02:54
Powershell script to extract the audio from a downloaded video file (e.g. a Youtube video).
[CmdletBinding()]
param (
[Parameter(ValueFromRemainingArguments=$true)]
$Path
)
# This script extracts the audio content from downloaded videos. It's meant to be run by drag-and-dropping the video
# onto the script. However since you can't do that directly to Powershell scripts, set it up this way:
# 1. Install Powershell
# 2. Make a shortcut to this script on your Desktop (call it what you like)
@coverprice
coverprice / gist:33f1cecb1ee9d16f94914edd5a6bfb8e
Created March 21, 2025 04:30
userChrome.css for Firefox to disable mute and play buttons in tabs
/* Hide the mute/unmute button */
.tab-icon-overlay:not([pinned], [sharing], [crashed]):is([soundplaying], [muted], [activemedia-blocked]) {
display: none !important;
}
/* Keep site icon visible on hover */
.tabbrowser-tab:hover .tab-icon-stack:not([pinned], [sharing], [crashed]):is([soundplaying], [muted], [activemedia-blocked]) > :not(.tab-icon-overlay),
/* for site icon with Compact density */
:root[uidensity="compact"] .tab-icon-stack:not([pinned], [sharing], [crashed]):is([soundplaying], [muted], [activemedia-blocked]) > :not(.tab-icon-overlay) {
opacity: 1 !important; /* overrides full transparency with full opacity */
}