Skip to content

Instantly share code, notes, and snippets.

@pahud
Created June 11, 2025 00:20
Show Gist options
  • Save pahud/98b817c7a0f2ade1174621cc2a5f6aa0 to your computer and use it in GitHub Desktop.
Save pahud/98b817c7a0f2ade1174621cc2a5f6aa0 to your computer and use it in GitHub Desktop.
~/.local/bin/qchat.sh
#!/bin/bash
echo "Searching for trusted tools..."
TOOLS=$(grep -v "not trusted$" "$0" | grep "trusted$" | sed 's/^- \([^ ]*\).*/\1/' | tr '\n' ',' | sed 's/,$//')
echo "Found tools: $TOOLS"
if [ -z "$TOOLS" ]; then
echo "Warning: No trusted tools found!"
exit 1
fi
echo "Using trusted tools: $TOOLS"
q chat --trust-tools "$TOOLS"
exit 0
Built-in:
- execute_bash not trusted
- fs_read trusted
- fs_write not trusted
- report_issue not trusted
- use_aws not trusted
@pahud
Copy link
Author

pahud commented Jun 11, 2025

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment