Skip to content

Instantly share code, notes, and snippets.

@codeedog
codeedog / 00 - Overview
Last active February 17, 2026 17:26
FreeBSD 15 Bridges, VLANs and Jails - Nice!
Complex network topology between host and jail with vlan aware bridges and epair trunks. Network set up to ping from one side to the other while traversing the trunk at the host/jail border half a dozen times. tcpdump shows the vlan at the crossings.
@b0gdanw
b0gdanw / Disable-Sequoia-Bloatware.sh
Last active March 13, 2026 17:31
Disable Sequoia Bloatware
#!/bin/zsh
# WARNING! The script is meant to show how and what can be disabled. Don’t use it as it is, adapt it to your needs.
# Credit: Original idea and script disable.sh by pwnsdx https://gist.github.com/pwnsdx/d87b034c4c0210b988040ad2f85a68d3
# Disabling unwanted services on macOS Big Sur (11), macOS Monterey (12), macOS Ventura (13), macOS Sonoma (14) and macOS Sequoia (15)
# Disabling SIP is required ("csrutil disable" from Terminal in Recovery)
# Modifications are written in /private/var/db/com.apple.xpc.launchd/ disabled.plist, disabled.501.plist
# To revert, delete /private/var/db/com.apple.xpc.launchd/ disabled.plist and disabled.501.plist and reboot; sudo rm -r /private/var/db/com.apple.xpc.launchd/*
# user
@psymonryan
psymonryan / macos_snapshot_fix.md
Last active March 16, 2026 12:13
Update error: A snapshot is currently set to boot that is not the currently booted snapshot [solved]

Fix for "A snapshot is currently set to boot that is not the currently booted snapshot" issue

I spent a while figuring this one out. Here is what I did to render it [Solved] on my Dad's new Sonoma iMac. (BTW: I caused this problem in the first place by enabling his nfsd service, then adding and tagging the snapshot as bootable)

  1. Boot into recovery mode, open the terminal and disable SIP

    csrutil disable

  2. Reboot at this point back into Recovery mode and this time open up DiskUtil

#!/bin/zsh
# WARNING! The script is meant to show how and what can be disabled. Don’t use it as it is, adapt it to your needs.
# Credit: Original idea and script disable.sh by pwnsdx https://gist.github.com/pwnsdx/d87b034c4c0210b988040ad2f85a68d3
# Disabling unwanted services on macOS Big Sur (11), macOS Monterey (12), macOS Ventura (13) and macOS Sonoma (14)
# Disabling SIP is required ("csrutil disable" from Terminal in Recovery)
# Modifications are written in /private/var/db/com.apple.xpc.launchd/ disabled.plist, disabled.501.plist
# To revert, delete /private/var/db/com.apple.xpc.launchd/ disabled.plist and disabled.501.plist and reboot; sudo rm -r /private/var/db/com.apple.xpc.launchd/*
# user
@stephancasas
stephancasas / sonoma-text-insertion-point-downgrade.jxa.js
Created October 7, 2023 02:58
Disable Sonoma Text Insertion Point ("Cursor" / "Caret")
#!/usr/bin/env osascript -l JavaScript
const App = Application.currentApplication();
App.includeStandardAdditions = true;
const kCFPrefsFeatureFlagsDir = '/Library/Preferences/FeatureFlags/Domain';
const kCFPrefsFeatureEnabledKey = 'Enabled';
const kUIKitDomainPrefsTemporaryPath = '/tmp/UIKit.plist';
const kUIKitRedesignedTextCursorKey = 'redesigned_text_cursor';
@sdrapha
sdrapha / mc-wrapper.fish
Created July 1, 2023 18:41
mc-wrapper.fish
function mc
set SHELL_PID %self
if not test -d "/tmp/mc-$USER"
mkdir -p "/tmp/mc-$USER"
end
set MC_PWD_FILE "/tmp/mc-$USER/mc.pwd.$SHELL_PID"
/usr/bin/mc -P $MC_PWD_FILE $argv
@Adito5393
Adito5393 / archlinuxzbm.md
Last active February 1, 2026 10:44 — forked from jimboy-701/archlinuxzbm.md
Arch Linux with ZFS root, zfs-dkms, ZFSBootMenu, and Secure Boot enabled (nothing changed compared to the upstream - last merged upstream revision 2024-02-22)

Install Arch Linux with ZFS root filesystem, zfs-dkms, ZFSBootMenu, Pacman Auto-snapshots, Secure Boot enabled

Configure system BIOS

Disable Secure Boot. ZFS modules can not be loaded if Secure Boot is enabled.

ZFS automated install script

Before moving on I need to point out that there exists a script that can automate the configuration and install of a ZFS root system. However as convenient as it sounds the script is limited in flexibility and scope. These limitation cannot be overcome unless one has the time and compacity to edit the script to their liking. If you want to install a ZFS root system as quickly as possible and don't care about any particulars than take a good look at this github page.

@ianthetechie
ianthetechie / bhyve-debian.md
Created February 1, 2023 04:39
A short guide on setting up Debian guests in bhyve

A short guide on setting up Debian guests in bhyve

I have a problem. I need to run some Docker containers for work. Docker, as you may know, has a design that is tightly coupled to Linux. This is rather unfortunate since my desktop is running FreeBSD, and my laptop is running its distant cousin, macOS. Normally I'd just do such things on my Mac, but 1) my desktop has a lot more storage, and 2) the Docker images in question are amd64 already. Also I just wanted a challenge, so let's set up a VM to run Docker on FreeBSD.

Aside in case you're wondering why Docker runs on your Mac: Docker Desktop actually ships a hypervisor,

@macshome
macshome / defang.md
Last active March 9, 2026 19:20
How to defang system protections on macOS

How to Defang macOS System Protections

If you want to change things on the root drive of a Mac you will need to take some steps to disable the built in security of the system. Most of these steps are the same regardless if you are on Intel or Apple Silicon. If there is a difference it is noted.

Note that all of these things put a Mac into an unsupported and less secure state.

Make sure you either perform these steps in a VM or that you reset the protections after you are done poking around

Protections and Terms

(This list is not exahustive on the details of each. Check the links at the end for more info.)