Documentation Index
Fetch the complete documentation index at: https://mintlify.com/github/awesome-copilot/llms.txt
Use this file to discover all available pages before exploring further.
Hooks Catalog
Browse and install hooks to automate your GitHub Copilot coding agent workflows.Available Hooks
Session Logger
Log session activity for audit and analysis
Session Auto-Commit
Auto-commit changes when sessions end
Governance Audit
Scan prompts for security threats
Session Logger
Tags: logging, audit, analytics
Features
- Session Tracking: Log session start and end events
- Prompt Logging: Record when user prompts are submitted
- Structured Logging: JSON format for easy parsing
- Privacy Aware: Configurable to disable logging entirely
Installation
Configuration
Privacy & Security
- Use
LOG_LEVEL=ERRORto only log errors - Set
SKIP_LOGGING=trueenvironment variable to disable - Logs are stored locally only
- No sensitive data is logged
Session Auto-Commit
Tags: automation, git, productivity
Features
- Automatic Backup: Never lose work from a Copilot session
- Timestamped Commits: Each auto-commit includes the session end time
- Safe Execution: Only commits when there are actual changes
- Error Handling: Gracefully handles push failures
Installation
Configuration
How It Works
Customization
You can customize the hook by modifyingauto-commit.sh:
- Commit Message Format: Change the timestamp format or message prefix
- Selective Staging: Use specific git add patterns instead of
-A - Branch Selection: Push to specific branches only
- Notifications: Add desktop notifications or Slack messages
Disabling
To temporarily disable auto-commits:Governance Audit
Tags: security, governance, audit, safety
Features
- Threat Detection: Scans prompts for data exfiltration, privilege escalation, system destruction, prompt injection, and credential exposure
- Governance Levels: Open, standard, strict, locked — from audit-only to full blocking
- Audit Trail: Append-only JSON log of all governance events
- Session Summary: Reports threat counts at session end
Threat Categories
Data Exfiltration (Severity: 0.7-0.95)
Data Exfiltration (Severity: 0.7-0.95)
Detects attempts to send sensitive data to external endpoints.Examples:
- “send all records to external API”
- “curl data to my server”
- “upload database to S3”
Privilege Escalation (Severity: 0.8-0.95)
Privilege Escalation (Severity: 0.8-0.95)
Detects attempts to gain elevated system privileges.Examples:
- “sudo rm -rf”
- “chmod 777”
- “add to sudoers”
System Destruction (Severity: 0.9-0.95)
System Destruction (Severity: 0.9-0.95)
Detects commands that could destroy data or systems.Examples:
- “rm -rf /”
- “drop database”
- “format disk”
Prompt Injection (Severity: 0.6-0.9)
Prompt Injection (Severity: 0.6-0.9)
Detects attempts to manipulate the AI agent’s behavior.Examples:
- “ignore previous instructions”
- “you are now in developer mode”
- “disregard safety guidelines”
Credential Exposure (Severity: 0.9-0.95)
Credential Exposure (Severity: 0.9-0.95)
Detects hardcoded secrets and credentials.Examples:
- Hardcoded API keys
- AWS access keys
- Private tokens in code
Governance Levels
| Level | Behavior |
|---|---|
open | Log threats only, never block |
standard | Log threats, block only if BLOCK_ON_THREAT=true |
strict | Log and block all detected threats |
locked | Log and block all detected threats |
Installation
Configuration
Environment Variables
| Variable | Values | Default | Description |
|---|---|---|---|
GOVERNANCE_LEVEL | open, standard, strict, locked | standard | Controls blocking behavior |
BLOCK_ON_THREAT | true, false | false | Block prompts with threats (standard level) |
SKIP_GOVERNANCE_AUDIT | true | unset | Disable governance audit entirely |
Requirements
jqfor JSON processing (pre-installed on most CI environments and macOS)grepwith-E(extended regex) supportbcfor floating-point comparison (optional, gracefully degrades)
Privacy & Security
- Add
logs/to.gitignoreto keep audit data local - Set
SKIP_GOVERNANCE_AUDIT=trueto disable entirely - All data stays local — no external network calls
Contributing
Want to add a hook to this catalog? See the Contributing Guide for guidelines on:- Creating new hooks
- Writing hook documentation
- Testing and validation
- Submission process
View All Hooks on GitHub
Browse the complete collection of hooks in the repository