Skip to content

Instantly share code, notes, and snippets.

@rmtbb
rmtbb / chatGptDelay-Bookmarklet.url
Last active September 23, 2024 06:20
Bookmarklet: ChatGPT Delay Send
javascript:(function(){ var time = prompt("Enter delay in minutes or seconds (e.g., '5s' for 5 seconds or '4m' for 4 minutes). If not specified, default is minutes:"); var delay; if (time.endsWith('s')) { delay = parseInt(time) * 1000; } else if (time.endsWith('m') || !time.match(/\d+[sm]/)) { delay = parseInt(time) * 60000; } else { delay = parseInt(time) * 60000; } setTimeout(() => { var button = document.querySelector('body > div.relative.flex.h-full.w-full.overflow-hidden.transition-colors.z-0 > div.relative.flex.h-full.max-w-full.flex-1.flex-col.overflow-hidden > main > div.composer-parent.flex.h-full.flex-col.focus-visible\\:outline-0 > div.md\\:pt-0.dark\\:border-white\\/20.md\\:border-transparent.md\\:dark\\:border-transparent.w-full > div > div.text-base.px-3.md\\:px-4.m-auto.w-full.md\\:px-5.lg\\:px-4.xl\\:px-5 > div > form > div > div.group.relative.flex.w-full.items-center > div.flex.w-full.flex-col.gap-1\\.5.rounded-\\[26px\\].p-1\\.5.transition-colors.bg-\\[\\#f4f4f4\\].dark\\:bg-token-main-surf
@rmtbb
rmtbb / shanegillis-dates.sh
Created June 27, 2024 05:21
Bash script to return Shane Gillis' upcoming tour dates from his website
curl -s "https://rest.bandsintown.com/artists/Shane%20Gillis/events?app_id=squarespace-moose-pelican-53kl&date=upcoming" | jq '[.[] | select(.offers[]?.type == "Tickets") | {Date: .starts_at, "Artist Name": .lineup[0], "City and State": "\(.venue.city), \(.venue.region)", "Venue Name": .venue.name, "Tickets URL": (.offers[] | select(.type == "Tickets").url)}] | sort_by(.Date)'
nohup zsh -c 'while true; do voice=$(say -v "?" | awk "{print \$1}" | sort -R | head -1); say -v "$voice" "It is now $(date "+%l %M %p")."; sleep $((30 + RANDOM % 1971)); done' &
nohup bash -c "ps aux | grep '[s]ay' | awk '{print \$2}' | xargs kill" &
nohup bash -c 'for i in {0..100}; do voice=$(say -v "?" | awk "{print \$1}" | sort -R | head -1); rate=$((50 + RANDOM % 150)); say -v "$voice" -r $rate $i; done' &