Skip to content

Instantly share code, notes, and snippets.

View hobbsy's full-sized avatar

Jim Hobbs hobbsy

View GitHub Profile
@fawazahmed0
fawazahmed0 / cloudflare-tld-price-list.csv
Last active November 7, 2024 01:37
cloudflare domains price list for tlds
TLD Registration Fees Renewal Fees
example.org.uk 4.94 4.94
example.uk 4.94 4.94
example.me.uk 4.94 4.94
example.co.uk 4.94 4.94
example.date 4.16 5.16
example.trade 4.16 5.16
example.party 4.16 5.16
example.bid 4.16 5.16
example.stream 4.16 5.16
@aileftech
aileftech / hex-colors.txt
Created October 1, 2022 18:10
A Bash one-liner to produce a list of HEX color codes that read like (supposedly) valid English words
$ grep -P "^[ABCDEFabcdefOoIi]{6,6}$" /usr/share/dict/words | tr 'OoIi' '0011' | tr '[:lower:]' '[:upper:]' | awk '{print "#" $0}'
#ACAD1A
#B0BB1E
#DEBB1E
#AB1DED
#ACAC1A
#ACCEDE
#AC1D1C
#BAB1ED
#BA0BAB
@fawazahmed0
fawazahmed0 / comment.js
Created August 31, 2022 16:50
Youtube comment scrape
const { firefox } = require('playwright');
const fs = require('fs')
const path = require('path')
async function begin(){
let count = 0
let browser = await firefox.launch({headless: false});
let context = await browser.newContext({viewport:{width:400,height:700}});
let page = await context.newPage();
let values = ["/watch?v=VikfS15Ymmw","/watch?v=ndaEzlg5xcg","/watch?v=XexTm02fumM","/watch?v=sRIB9kVzjYM","/watch?v=TSNNi7qSpCc","/watch?v=rbdVDwMbqlE","/watch?v=rfrg-Oo13GI","/watch?v=U1s48KT2KME","/watch?v=KdA-9wK_wVw","/watch?v=KrjvEvYGFUI","/watch?v=LgDKD87Cwqk","/watch?v=ck7bzakwmnQ","/watch?v=lkJ_an81sbI","/watch?v=72N0pRsSIFQ","/watch?v=QzsfZU1q-SQ","/watch?v=c8y5UTwMuyY","/watch?v=pI46I7pSc4g","/watch?v=RzYlGaLGn2o","/watch?v=bTE2wZeiVz4","/watch?v=doIfZm2iGnA","/watch?v=N-9CWbNo9Fg","/watch?v=XJpmfW60OuE","/watch?v=rh3ohhR1iYI","/watch?v=3XMPLN3cyxs","/watch?v=p-VvH1KDvAM","/watch?v=TLnmBLqIMqs","/watch?v=WHvJuEA00V0","/watch?v=3j_9p1VOTPI","/watch?v=waXGqCwoBLY","/watch?v=zHRDtD8t1v0","/wat
@RhetTbull
RhetTbull / vision.py
Last active November 13, 2024 09:24
Use Apple's Vision framework from Python to detect text in images
""" Use Apple's Vision Framework via PyObjC to detect text in images
To use:
python3 -m pip install pyobjc-core pyobjc-framework-Quartz pyobjc-framework-Vision wurlitzer
"""
import pathlib
@cellularmitosis
cellularmitosis / README.md
Last active April 26, 2024 06:45
Quick-n-dirty QEMU script to spin up Debian on various CPU's
@geerlingguy
geerlingguy / pi-general-benchmark.sh
Last active November 1, 2024 21:48
Raspberry Pi Benchmark Suite - Phoronix
#!/bin/bash
#
# Benchmark script for Raspberry Pi OS.
#
# WARNING: This script is meant to be run as the root user.
# This script should never be run on a system/partition you
# care about. You should only run this on a system that you
# intend to use only for benchmarking and can reinstall or
# re-flash easily.
#
@geerlingguy
geerlingguy / pi-cpu-stress.sh
Last active September 18, 2024 17:26
Raspberry Pi CPU temperature and throttling test script
#!/bin/bash
# Raspberry Pi stress CPU temperature measurement script.
#
# Download this script (e.g. with wget) and give it execute permissions (chmod +x).
# Then run it with ./pi-cpu-stress.sh
#
# NOTE: In recent years, I've switched to using s-tui. See:
# https://github.com/amanusk/s-tui?tab=readme-ov-file#options
# Variables.
@leodutra
leodutra / -setup-windows-wsl-devenv.md
Last active November 4, 2024 01:46
Install and Setup Windows Subsystem 2 for Linux, Hyper, ZSH + Oh My Zsh + Powerlevel9k + plugins, FNM + VSCode (+ext) and Nerd Font

Setup Windows Subsystem 2 for Linux

Windows Subsystem 2 for Linux, Hyper, ZSH + Oh My Zsh + Powerlevel9k + plugins, FNM + VSCode (+ext) and Nerd Font

To setup native Linux, see this gist

Preview

Requirements

@daviddarnes
daviddarnes / gulpfile.js
Last active June 10, 2023 01:17
Import your Ghost posts into a Jekyll project using Gulp
const File = require('vinyl');
const gulp = require("gulp");
const Handlebars = require('handlebars');
const streamArray = require('stream-array');
const ghostContentAPI = require("@tryghost/content-api");
const api = new ghostContentAPI({
url: 'https://demo.ghost.io',
key: '22444f78447824223cefc48062',
version: "v4"
@rcarmo
rcarmo / bt-agent.service
Last active December 12, 2023 13:14
Set up PAN networking on Raspbian Stretch (use sudo to create these files and run all commands)
# in /etc/systemd/system
[Unit]
Description=Bluetooth Agent
[Service]
ExecStart=/usr/bin/bt-agent -c NoInputNoOutput
Type=simple
[Install]
WantedBy=multi-user.target