Skip to content

Instantly share code, notes, and snippets.

View thesobercoder's full-sized avatar
😎
Talk is cheap show me the code!

Soham Dasgupta thesobercoder

😎
Talk is cheap show me the code!
View GitHub Profile
Set up these as real Codex lifecycle hooks by following the official documentation:
https://learn.chatgpt.com/docs/hooks
Important: use ~/.codex/hooks.json and a PreToolUse command hook. Do not implement this only as a ~/.codex/rules/*.rules execution-policy file.
First inspect any existing hooks and preserve them. Then:
1. Create or merge ~/.codex/hooks.json with a PreToolUse matcher for Bash.
2. Create ~/.codex/hooks/destructive_commands.py.
3. The script must read the hook JSON payload from stdin and inspect tool_input.command.
@thesobercoder
thesobercoder / install-zsh-windows-git-bash.md
Created August 14, 2024 08:43 — forked from fworks/install-zsh-windows-git-bash.md
Zsh / Oh-my-zsh on Windows Git Bash