Skip to content

Instantly share code, notes, and snippets.

View pythoninthegrass's full-sized avatar

pythoninthegrass

View GitHub Profile
@pythoninthegrass
pythoninthegrass / com.user.headroom.proxy.plist
Created January 14, 2026 21:13
Headroom proxy server launchagent to reduce LLM context size
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.user.headroom.proxy</string>
<key>ProgramArguments</key>
<array>
<string>/Users/lance/.local/bin/headroom</string>
<string>proxy</string>
@pythoninthegrass
pythoninthegrass / com.user.mole.nightly.plist
Created January 14, 2026 21:11
Mole launchagent for nightly macOS cleanup
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.user.mole.nightly</string>
<key>ProgramArguments</key>
<array>
<string>/opt/homebrew/bin/mo</string>
<string>clean</string>
@pythoninthegrass
pythoninthegrass / config.txt
Created November 6, 2025 19:36
Working PiFire DSI config
# For more options and information see
# http://rptl.io/configtxt
# Some settings may impact device functionality. See link above for details
# Uncomment some or all of these to enable the optional hardware interfaces
dtparam=i2c_arm=on # Modified by PiFire Board Configuration Utility
#dtparam=i2s=on
dtparam=spi=on # Modified by PiFire Board Configuration Utility
# Enable audio (loads snd_bcm2835)
@pythoninthegrass
pythoninthegrass / marimo.toml
Created October 28, 2025 19:01
Marimo config
[experimental]
[completion]
copilot = "github"
activate_on_typing = true
[save]
autosave_delay = 3000
format_on_save = false
autosave = "after_delay"
@pythoninthegrass
pythoninthegrass / com.user.disable-rcd.plist
Created October 12, 2025 02:21
Disable Apple Music (née iTunes) from launching via media keys
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.user.disable-rcd</string>
<key>ProgramArguments</key>
<array>
<string>/bin/launchctl</string>
<string>unload</string>
@pythoninthegrass
pythoninthegrass / .env.example
Last active January 20, 2026 06:55
opencode config
CONTEXT7_API_KEY=
@pythoninthegrass
pythoninthegrass / sysctl.plist
Last active September 7, 2025 20:10
Set macOS VRAM persistently
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.user.sysctl</string>
<key>ProgramArguments</key>
<array>
<string>/usr/sbin/sysctl</string>
<string>-w</string>
# /etc/caddy/Caddyfile
{
auto_https disable_redirects
}
:80 {
respond "Hello from HTTP port 80"
}
@pythoninthegrass
pythoninthegrass / cig_coc_sum_squares.py
Created September 4, 2025 19:08
codingame.com - sum of squared numbers
"""
INPUT:
Line 1: An integer N for the amount of numbers to use.
Line 2: A line containing N space-separated integers Xi.
OUTPUT:
The sum of the squares of the Xi numbers.
CONSTRAINTS:
0 < N < 100
#!/usr/bin/env -S uv run --script
# /// script
# requires-python = ">=3.12"
# dependencies = [
# "python-decouple>=3.8",
# ]
# [tool.uv]
# exclude-newer = "2025-07-21T00:00:00Z"
# ///