Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
120 changes: 8 additions & 112 deletions config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@
# Organization to monitor
organization: pulseengine

# Bot mention name (without [bot] suffix)
bot_name: temper-pulseengine

# Users authorized to trigger commands
allowed_command_users:
- avrabe

# Target settings for repositories
settings:
merge:
Expand All @@ -11,20 +18,18 @@ settings:
allow_rebase_merge: true
delete_branch_on_merge: true

# Forked repositories can use slightly looser merge settings
forks:
merge:
allow_merge_commit: true
allow_squash_merge: true
allow_rebase_merge: true
delete_branch_on_merge: true

# Branch protection rules (applied to the repository default branch)
branch_protection:
default:
required_status_checks:
strict: true
contexts: ['ci', 'lint', 'test']
contexts: ["ci", "lint", "test"]
enforce_admins: true
required_pull_request_reviews:
required_approving_review_count: 1
Expand All @@ -37,18 +42,7 @@ branch_protection:
allow_force_pushes: false
allow_deletions: false
require_signed_commits: true
fork_overrides:
# Loosened defaults for forked repositories
enforce_admins: false
required_status_checks: null
required_pull_request_reviews: null
required_linear_history: false
required_conversation_resolution: false
allow_force_pushes: true
allow_deletions: true
require_signed_commits: false

# Standard issue labels
issue_labels:
- name: "bug"
color: "d73a4a"
Expand All @@ -74,101 +68,3 @@ issue_labels:
- name: "automation"
color: "0e8a16"
description: "Automation updates"

# Pull request rules
pull_request_rules:
required_approving_reviews: 1
require_code_owner_reviews: true
dismiss_stale_reviews: true
require_last_push_approval: true
required_status_checks:
- "ci"
- "lint"
- "test"

# Signed commit merge strategy
signed_commit_strategy:
allow_merge_commits_for_signed: true
temporary_rule_timeout: 3600000 # 1 hour in milliseconds
admin_users:
- "avrabe"
# List of branches where this applies
protected_branches:
- "main"
- "master"
- "production"

# CI attestation requirements
ci_attestation:
required_for_main_branch: true
required_checks:
- "security-scan"
- "vulnerability-check"
- "license-compliance"
attestation_format: "sigstore"

# Dependabot configuration
dependabot:
version: 2
updates:
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "daily"
time: "09:00"
timezone: "UTC"
open-pull-requests-limit: 10
target-branch: "main"
reviewers:
- "avrabe"
assignees:
- "avrabe"
labels:
- "dependencies"
- "automation"
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
day: "monday"
time: "09:00"
timezone: "UTC"

# Configuration change strategy
change_strategy:
use_pull_requests: true
pr_title: "[Bot] Repository Configuration Update"
pr_body: "This PR updates repository configuration to match organization standards."
pr_reviewers:
- "avrabe"
pr_labels:
- "automation"
- "configuration"
require_approval: true
auto_merge: false

# Issue/PR templates to apply
templates:
pull_request: .github/PULL_REQUEST_TEMPLATE.md
issue: .github/ISSUE_TEMPLATE/

# CODEOWNERS file to apply
codeowners: .github/CODEOWNERS

# AI-powered PR review (requires a local OpenAI-compatible endpoint)
ai_review:
enabled: false
endpoint: ""
model: ""
max_diff_size: 12000
max_tokens: 2000
temperature: 0.3
timeout: 120000
allow_remote_endpoint: false
system_prompt: |
You are a thorough code reviewer. Analyze the PR diff and provide:
1. Summary of changes
2. Potential bugs or issues
3. Security concerns
4. Suggestions for improvement
5. Overall assessment
5 changes: 4 additions & 1 deletion src/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ function registerApp(app, { getRouter, addHandler } = {}) {
});

app.on('issue_comment.created', async (context) => {
if (!context.octokit) { return; }
if (context.log) setLogger(context.log);
const deliveryId = context.id;
if (deliveryId && isProcessed(deliveryId)) {
Expand All @@ -112,7 +113,8 @@ function registerApp(app, { getRouter, addHandler } = {}) {

const config = getConfig();
const { comment, repository, sender } = context.payload;
if (!comment?.body || !context.octokit) {

if (!comment?.body || !context.octokit?.issues) {
return;
}

Expand Down Expand Up @@ -168,6 +170,7 @@ function registerApp(app, { getRouter, addHandler } = {}) {
};

// Use extracted command (supports both /command and @botname command)
getLogger().info({ commandBody, extractedCommand, botName }, "Debug: command parsing");
const cmd = extractedCommand;

if (cmd === '/configure-repo') {
Expand Down