File tree Expand file tree Collapse file tree 1 file changed +53
-0
lines changed Expand file tree Collapse file tree 1 file changed +53
-0
lines changed Original file line number Diff line number Diff line change 1+ # Advanced Custom Trigger Conditions Example
2+ # This example demonstrates using custom_trigger_condition for advanced use cases
3+ # beyond the default @claude mention detection.
4+
5+ name : Claude code when mentioned
6+
7+ # Concurrency control to prevent multiple jobs running for the same PR/issue
8+ concurrency :
9+ group : claude-${{ github.event.pull_request.number || github.event.issue.number || 'manual' }}
10+ cancel-in-progress : false
11+
12+ on :
13+ workflow_dispatch :
14+ inputs :
15+ test_mode :
16+ description : ' Test mode for debugging'
17+ required : false
18+ type : boolean
19+ default : false
20+ issue_comment :
21+ types : [created]
22+ pull_request_review_comment :
23+ types : [created]
24+
25+ jobs :
26+ claude-code-review :
27+ uses :
dotCMS/ai-workflows/.github/workflows/[email protected] 28+ with :
29+ trigger_mode : interactive
30+ # Custom condition: Only trigger when files in core-web directory are changed
31+ custom_trigger_condition : |
32+ github.event_name == 'pull_request' && (
33+ contains(toJSON(github.event.pull_request.files.*.filename), 'core-web/')
34+ )
35+ direct_prompt : |
36+ This PR appears to modify configuration files or has many changes.
37+ Please review for:
38+ - Configuration syntax and validity
39+ - Potential breaking changes
40+ - Security implications of config changes
41+ - Impact on existing functionality
42+ allowed_tools : |
43+ Bash(git status)
44+ Bash(git diff)
45+ Bash(grep -r "config" .)
46+ timeout_minutes : 15
47+ runner : ubuntu-latest
48+ enable_mention_detection : false
49+ secrets :
50+ ANTHROPIC_API_KEY : ${{ secrets.ANTHROPIC_API_KEY }}
51+
52+
53+
You can’t perform that action at this time.
0 commit comments