Skip to content

Instantly share code, notes, and snippets.

View jaredmdobson's full-sized avatar
🤚
Hi

Jared Dobson jaredmdobson

🤚
Hi
  • Cedar City, UT
View GitHub Profile
@jaredmdobson
jaredmdobson / ai-dotfiles-chezmoi.md
Created May 20, 2026 16:09
Tracking AI tool config (~/.claude, ~/.codex, ~/.aider, ...) with chezmoi

Tracking AI tool config (~/.claude, ~/.codex, ~/.aider, …) with chezmoi

A practical recipe for keeping the authored parts of your AI tools (instructions, skills, agents, commands, prompts, settings) in git while leaving the runtime junk (chat history, project caches, transcripts, telemetry, plugins) out of it.

This guide is written for both humans and agents handed the job "set up dotfile management for my AI tools." Follow it top-to-bottom on a fresh machine, or jump to Adding a new AI tool if chezmoi is already initialized.


Why chezmoi (and not git directly)

@jaredmdobson
jaredmdobson / auto-pull-mac.md
Created May 14, 2026 16:48
Auto-pull every git repo in ~/Developer on macOS (gitup + launchd, 30-min interval)

Auto-pull every git repo in ~/Developer on macOS

Keep all your local clones up to date in the background, so you never cd into a stale checkout. Uses gitup + a launchd agent that fires every 30 minutes.

gitup is "safe by default" — it skips dirty working trees, diverged branches, and detached HEADs instead of clobbering them. Combine it with the discipline of only editing inside a git worktree and your main checkouts stay clean mirrors of origin.


1. Prereqs

MCP Hot-Reload Pattern for AI Agents

A language-agnostic guide for implementing hot-reloadable MCP (Model Context Protocol) servers that update tools without process restarts.

The Problem

When building MCP servers for AI agents (Claude, GPT, etc.), code changes typically require:

  1. Stopping the MCP server
  2. Restarting the AI agent/IDE
  3. Reconnecting everything
@jaredmdobson
jaredmdobson / SafeTextField.kt
Created May 25, 2022 19:55
Prevent DEL Button crashing on jetpack compose android textfield
@Composable
fun SafeTextField(modifier = Modifier){
TextField(
modifier = modifier.onPreviewKeyEvent {
it.nativeKeyEvent.keyCode == KeyEvent.KEYCODE_DEL
}
)
@jaredmdobson
jaredmdobson / gist:5a94fb2a43157953d017fc2dd0fdd03e
Created April 29, 2021 14:26
Find out which certificate a macos was signed with.
codesign -d --extract-certificates ./[App Name Here].app;
openssl x509 -inform DER -in codesign0 -out codesign0.pem;
openssl x509 -inform DER -in codesign1 -out codesign1.pem;
openssl x509 -inform DER -in codesign2 -out codesign2.pem;
cat codesign1.pem codesign2.pem > cachain.pem;
openssl x509 -inform DER -in codesign0 -noout -nameopt -oneline -subject -serial -dates;
@jaredmdobson
jaredmdobson / gist:1da04297140e07fdfebb2b42def9e94a
Created March 2, 2021 17:42
Localhost and domain only regex
/^((\b(localhost)\b:[0-9]+)|([a-z0-9][a-z0-9-]{1,61}[a-z0-9](?:\.[a-z]{2,})+(:[0-9]+)?))$/
@jaredmdobson
jaredmdobson / upgrade-jenkins.sh
Last active June 14, 2018 17:27 — forked from cyxou/upgrade-jenkins.sh
Upgrade Jenkins on Bitnami VM
#!/bin/bash
sudo /opt/bitnami/ctlscript.sh stop tomcat
cd /opt/bitnami
sudo cp -f apache-tomcat/webapps/jenkins.war apps/jenkins/jenkins.war.bak
sudo rm -r apache-tomcat/webapps/jenkins
sudo rm -r apache-tomcat/webapps/jenkins.war
sudo rm -r apache-tomcat/work/Catalina/localhost/jenkins
sudo wget http://mirrors.jenkins-ci.org/war/latest/jenkins.war
sudo mv jenkins.war apache-tomcat/webapps/
@jaredmdobson
jaredmdobson / tasks.json
Created April 9, 2018 04:24
VS Code Rust Cargo Tasks 2018
// Available variables which can be used inside of strings.
// ${workspaceRoot}: the root folder of the team
// ${file}: the current opened file
// ${fileBasename}: the current opened file's basename
// ${fileDirname}: the current opened file's dirname
// ${fileExtname}: the current opened file's extension
// ${cwd}: the current working directory of the spawned process
{
"version": "0.1.0",
"command": "cargo",
@jaredmdobson
jaredmdobson / launch.json
Last active April 9, 2018 04:24
VS Code Rust LLDB Debug Launch.json 2018
{
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.2.0",
"configurations": [
{
"name": "Debug",
"type": "lldb",
@jaredmdobson
jaredmdobson / sp_helpindex3.sql
Last active May 30, 2018 21:29
T-SQL sp_helpindex3 replaces sp_helpindex2
USE master
GO
IF OBJECT_ID('sp_helpindex2', 'P') IS NOT NULL
BEGIN
DROP PROCEDURE sp_helpindex2
END
IF OBJECT_ID('sp_helpindex3', 'P') IS NOT NULL
BEGIN
DROP PROCEDURE sp_helpindex3
END