Skip to content

Instantly share code, notes, and snippets.

@SethBling
SethBling / MarIO.lua
Created November 20, 2024 00:41 — forked from d12frosted/MarIO.lua
MarI/O by SethBling
-- MarI/O by SethBling
-- Feel free to use this code, but please do not redistribute it.
-- Intended for use with the BizHawk emulator and Super Mario World or Super Mario Bros. ROM.
if gameinfo.getromname() == "Super Mario World (USA)" then
Filename = "DP1.state"
ButtonNames = {
"A",
"B",
"X",
@mondain
mondain / public-stun-list.txt
Last active September 1, 2025 03:44
Public STUN server list
23.21.150.121:3478
iphone-stun.strato-iphone.de:3478
numb.viagenie.ca:3478
s1.taraba.net:3478
s2.taraba.net:3478
stun.12connect.com:3478
stun.12voip.com:3478
stun.1und1.de:3478
stun.2talk.co.nz:3478
stun.2talk.com:3478
@willurd
willurd / web-servers.md
Last active September 1, 2025 03:36
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000

Build colmap with CUDA support

Instructions are for Ubuntu 22.04, with some notes for Ubuntu 24.04 but I didn't test it on 24.04, only on 22.04.

We'll install the following versions:

  • Ubuntu 22.04 with nvidia-driver-580 and cuda 12.9.1 (from nvidia apt repository)
  • cmake 3.28.4 (installed via pip)
  • boost 1.74.0 (that comes from apt)
  • googletest 1.16.0 (cloned in ceres-solver/third_party)

Bank‑Based Anonymous Age Verification (BAV)

A zero‑storage, privacy‑preserving age check that leverages banks’ existing KYC — with the user as the transport layer.


TL;DR

  • Banks sign an age claim, not an identity. They never learn which site you’re visiting.
  • Merchants verify a short‑lived token against their own nonce and a one‑time WebAuthn key. No database required.
@aarondewindt
aarondewindt / docker.service
Last active September 1, 2025 03:32
Setup docker on the steamdeck
[Unit]
Description=Docker Application Container Engine
Documentation=https://docs.docker.com
After=network-online.target docker.socket firewalld.service containerd.service time-set.target
Wants=network-online.target containerd.service
Requires=docker.socket
[Service]
Type=notify
# the default is not to use systemd for cgroups because the delegate issues still
@Mansitoh
Mansitoh / registry_data.json
Created September 22, 2024 21:05
Minecraft 1.21 Registry Data (Json)
{
"minecraft:banner_pattern": {
"minecraft:base": {
"asset_id": "minecraft:base",
"translation_key": "block.minecraft.banner.base"
},
"minecraft:border": {
"asset_id": "minecraft:border",
"translation_key": "block.minecraft.banner.border"
},
@baoxfei
baoxfei / public.code-snippets
Last active September 1, 2025 03:26
公共代码片段仓库
{
"Print to console": {
"scope": "javascript,typescript,typescriptreact",
"prefix": "log",
"body": [
"// eslint-disable-next-line no-console",
"console.log('$1 :', $1);"
],
"description": "Log output to console"
},
# To set this up, first get tailscale working in an isolated linux shell:
# 1. sudo systemctl stop tailscaled.service
# 2. tailscaled -port 9993 -state tailscale-luks-setup.state -tun userspace-networking -socket ./tailscaled.sock
# 3. tailscale -socket ./tailscaled.sock up -hostname HOSTNAME-luks
# 4. tailscale -socket ./tailscaled.sock down
# 5. ctrl-c out of tailscaled
# 6 sudo systemctl start tailscaled.service
#
# Then add the .state file to your machine secrets and pass its path as tailscaleStatePath.
@symisc
symisc / remove-background-pixlab-api.rb
Created September 1, 2025 03:12
Programmatically remove backgrounds from input image using the PixLab BG-REMOVE API Endpoint - https://pixlab.io/endpoints/background-remove-api
require 'net/http'
require 'json'
require 'base64'
require 'uri'
# Programmatically remove backgrounds from input images using the PixLab BG-REMOVE API endpoint.
#
# Refer to the official documentation at: https://pixlab.io/endpoints/background-remove-api for the API reference
# guide and more code samples.