Skip to content

Instantly share code, notes, and snippets.

View turnipsoup's full-sized avatar
🍎

Jeremy Heckt turnipsoup

🍎
View GitHub Profile
@adtac
adtac / Dockerfile
Last active July 13, 2025 20:06
#!/usr/bin/env docker run
#!/usr/bin/env -S bash -c "docker run -p 8080:8080 -it --rm \$(docker build --progress plain -f \$0 . 2>&1 | tee /dev/stderr | grep -oP 'sha256:[0-9a-f]*')"
# syntax = docker/dockerfile:1.4.0
FROM node:20
WORKDIR /root
RUN npm install sqlite3
@ajaxray
ajaxray / 1_Typora_Callout.md
Last active April 30, 2025 15:31
Making Notion style callout in Typora using custom CSS

Making Notion style callout in Typora using custom CSS

Do you want this type of callouts in typora? CleanShot 2022-12-03 at 19 02 01@2x

It's simple.

  • Copy the contents of callout.css at the bottom of your user base.user.css file.
    • You'll the find the base.user.css in typora theme folder. (Preference > Appearance > "Open theme folder")
  • If no base.user.css file is found in that folder, create one.
@turnipsoup
turnipsoup / .vimrc
Last active December 8, 2022 19:05
My vim confiug
" Basics
syntax enable
set expandtab
set splitbelow
set ruler
set scrolloff=3 " lines above/below cursor
set fileformats=unix,mac,dos
set cursorline
set autoread " automatically reloads file if changed outside
set splitbelow " split new window below current window
@iosifnicolae2
iosifnicolae2 / Readme.md
Last active March 12, 2024 19:42
Youtube is Boring

How To Make Youtube Less Boring

Tutorial: https://www.youtube.com/watch?v=hIqMrPTeGTc
Paste the below code in your browser console (F12 > Console):

(()=>{
    markAllVideosAsNotBeingInteresting({
        iterations: 1
    });
})();
@turnipsoup
turnipsoup / ps5-finder.py
Created June 23, 2021 14:41
Script we used to alert us if the PS5 was in stock. You need a Discord webhook.
import requests, logging
import pandas as pd
import bs4 as bs
logging.basicConfig(filename="./ps5search.log", level=logging.INFO, format="%(asctime)s|%(levelname)s|%(message)s")
# Define the base URL and the webhook URL
stock_url = "https://www.nowinstock.net/videogaming/consoles/sonyps5/"
webhook_url = "<Discord_Webhook_URL>"
@turnipsoup
turnipsoup / pihole-docker-compose.yaml
Last active February 12, 2021 19:47
Script for running and updating a Pihole docker container. You use the same script the first time you start it up as well.
version: "3"
# More info at https://github.com/pi-hole/docker-pi-hole/ and https://docs.pi-hole.net/
services:
pihole:
container_name: pihole
image: pihole/pihole:latest
ports:
- "53:53/tcp"
- "53:53/udp"
@turnipsoup
turnipsoup / rsa_solver.py
Last active June 30, 2020 23:27
RSA Solver
# Sources
# https://stackoverflow.com/questions/4643647/fast-prime-factorization-module
# https://stackoverflow.com/questions/49856115/inverse-of-a-powa-b-n-function-in-python-decryption-code
# Solutions on cryptohack.org
## Imports
import binascii
import base64
from Crypto.Util.number import inverse, bytes_to_long, long_to_bytes
from sympy.ntheory import factorint
@satmandu
satmandu / make_current_arm64_rpi_kernel_debs.sh
Last active September 25, 2024 03:44
Make arm64 deb packages for the offical Raspberry Pi Foundation arm64 kernels, tested with ubuntu 23.04
#!/bin/bash -x
# make_arm64_rpi_kernel_debs.sh
# Builds arm64 debian packages from the CURRENT rpi firmware repository kernel which is installed by:
# sudo rpi-update
# This runs on an arm64 host with arm64 compilation tools...
# or with some sort of cross-compilation setup.
# Debs are put in $workdir/build
#
# This will NOT work in Raspbian unless you have an arm64 compilation
# environment setup. Appears to work on
@turnipsoup
turnipsoup / hanoi.go
Created February 14, 2020 20:39
The hanoi problem recursion solver from this computerfile video (but ported to Go): https://www.youtube.com/watch?v=8lhxIOAfDss&t=629s
package main
import (
"fmt"
"os"
"strconv"
)
func main() {
total_discs, _ := strconv.Atoi(os.Args[1])
@turnipsoup
turnipsoup / index.html
Created April 23, 2018 15:53
phone-number-cleaner
<head>
<title>Phone Number Cleaner</title>
<script
src="https://code.jquery.com/jquery-3.2.1.min.js"
integrity="sha256-hwg4gsxgFZhOsEEamdOYGBf13FyQuiTwlAQgxVSNgt4="
crossorigin="anonymous"></script>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
</head>
<div class='main-holder text-center'>