Skip to content

Instantly share code, notes, and snippets.

@itsmikita
itsmikita / macos-iso.md
Last active July 1, 2025 17:40
Extract ISO image from macOS Somona installer
@callemo
callemo / wg.sh
Last active July 4, 2025 11:48
WireGuard for OpenBSD
#!/bin/sh
gw="$(route -n show | awk '$1 == "default" { print $2 }')"
awk -v gw="$gw" '
$1 == "PrivateKey" { key = $3 }
$1 == "Address" {
addr = $3
sub(/,.*/, "", addr)
}
$1 == "DNS" { dns = $3 }
$1 == "PublicKey" { peer = $3 }
@kconner
kconner / macOS Internals.md
Last active July 2, 2025 14:28
macOS Internals

macOS Internals

Understand your Mac and iPhone more deeply by tracing the evolution of Mac OS X from prelease to Swift. John Siracusa delivers the details.

Starting Points

How to use this gist

You've got two main options:

@amunchet
amunchet / noVNCCopyPasteProxmox.user.js
Last active June 20, 2025 06:25
Copy/Paste for noVNC Proxmox
// ==UserScript==
// @name noVNC Paste for Proxmox
// @namespace http://tampermonkey.net/
// @version 0.2a
// @description Pastes text into a noVNC window (for use with Proxmox specifically)
// @author Chester Enright
// @match https://*
// @include /^.*novnc.*/
// @require http://code.jquery.com/jquery-3.3.1.min.js
// @grant none
@tomdaley92
tomdaley92 / README.md
Last active July 5, 2025 20:22
Proxmox - SPICE Client setup for MacOS

Proxmox - SPICE client setup for MacOS

  1. Install a working (and compiled) version of virt-viewer. You may view the homebrew package's upstream source on GitHub.

    brew tap jeffreywildman/homebrew-virt-manager
    brew install virt-viewer
  2. Once that's installed should be able make a call remote-viewer with a pve-spice.vv file downloaded from proxmox web interface

@sindresorhus
sindresorhus / esm-package.md
Last active July 6, 2025 04:40
Pure ESM package

Pure ESM package

The package that linked you here is now pure ESM. It cannot be require()'d from CommonJS.

This means you have the following choices:

  1. Use ESM yourself. (preferred)
    Use import foo from 'foo' instead of const foo = require('foo') to import the package. You also need to put "type": "module" in your package.json and more. Follow the below guide.
  2. If the package is used in an async context, you could use await import(…) from CommonJS instead of require(…).
  3. Stay on the existing version of the package until you can move to ESM.
@sxlijin
sxlijin / lighting_setup.md
Last active December 12, 2019 00:05
Portable nighttime sports field lighting setup

Portable outdoor nighttime sports field lighting setup

Ocean Beach pickup ultimate in SF uses the below described setup for nighttime beach frisbee games.

Regulation fields are 150' x 90', ours is probably slightly smaller.

We get 90+ min (probably 2h+) of playtime out of this setup (batteries can be upgraded if you want more time).

Bill of Materials (v2)

Kiosk Mode macOS

  1. Create two user accounts
    • Administration account
    • Kiosk Account - This account will be locked down with Parental Controls
  2. Set up remote management
  3. Install kiosk software
  • We use a role-based Apple ID (ex: webmaster@[institution].org) to manage macOS software. Managing Apps this way saves lots of headaches.
@dnknth
dnknth / Makefile
Last active April 20, 2023 18:46
Prepare an SD card with Alpine Linux for a Raspberry Pi
# Prepare an SD card with Alpine Linux for a Raspberry Pi
# See: https://wiki.alpinelinux.org/wiki/Raspberry_Pi
# Editable configuration
DISTRO = alpine
# ARCH = armhf
ARCH = aarch64
MAJOR_VERSION = 3.9
MINOR_VERSION = 2