Skip to content

Instantly share code, notes, and snippets.

@spelufo
Created May 4, 2026 13:56
Show Gist options
  • Select an option

  • Save spelufo/d95dad054e97dbaa15538ff365afa013 to your computer and use it in GitHub Desktop.

Select an option

Save spelufo/d95dad054e97dbaa15538ff365afa013 to your computer and use it in GitHub Desktop.
Quick and dirty osx sandbox for coding agents
sbox() {
sandbox-exec -f ~/bin/dotfiles/osx/sandbox.sb -D DIR="$(pwd)" "$@"
}
alias pi='sbox pi'
alias piro='sbox pi --tools read,grep,find,ls'
alias claude='sbox claude'
alias oc='sbox opencode'
; Configuration to prevent coding agents from touching user files outside the current directory.
(version 1)
(debug deny)
(allow default)
(deny file*
(regex "^/Users/spelufo/[^.]"))
(allow file*
(subpath "/Users/spelufo/bin")
(subpath (param "DIR")))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment