Skip to content

Instantly share code, notes, and snippets.

superwhite() { swift - "$1" "${1%.*}-hdr.jpg" <<'SW'
import Foundation; import CoreGraphics; import ImageIO; import UniformTypeIdentifiers
let a = CommandLine.arguments
guard a.count >= 3, let s = CGImageSourceCreateWithURL(URL(fileURLWithPath: a[1]) as CFURL, nil),
let c = CGImageSourceCreateImageAtIndex(s, 0, nil) else { print("usage: superwhite image.png"); exit(1) }
let w = c.width, h = c.height, r = w * 4
var b = [UInt8](repeating: 0, count: r * h)
let x = CGContext(data: &b, width: w, height: h, bitsPerComponent: 8, bytesPerRow: r,
space: CGColorSpace(name: CGColorSpace.sRGB)!, bitmapInfo: CGImageAlphaInfo.premultipliedLast.rawValue)!
x.setFillColor(red: 1, green: 1, blue: 1, alpha: 1); x.fill(CGRect(x: 0, y: 0, width: w, height: h))
@xvitaly
xvitaly / remove_crw.cmd
Last active September 11, 2026 15:12
Remove telemetry updates for Windows 7 and 8.1
@echo off
echo Uninstalling KB3075249 (telemetry for Win7/8.1)
start /w wusa.exe /uninstall /kb:3075249 /quiet /norestart
echo Uninstalling KB3080149 (telemetry for Win7/8.1)
start /w wusa.exe /uninstall /kb:3080149 /quiet /norestart
echo Uninstalling KB3021917 (telemetry for Win7)
start /w wusa.exe /uninstall /kb:3021917 /quiet /norestart
echo Uninstalling KB3022345 (telemetry)
start /w wusa.exe /uninstall /kb:3022345 /quiet /norestart
echo Uninstalling KB3068708 (telemetry)
@rdebath
rdebath / README
Last active August 20, 2026 09:12
Original brainfuck distribution by Urban Müller
This archive contains the following programs:
bfc The compiler for the 'brainfuck' language (240 bytes!)
bfc.asm Source for the compiler
bfi The interpreter for the 'brainfuck' language
bfi.c Source for the interpreter (portable)
src/ Some example programs in 'brainfuck'
src/atoi.b Reads a number from stdin
src/div10.b Divides the number under the pointer by 10
src/hello.b The ubiquitous "Hello World!"