mirror of
https://github.com/claude-code-best/claude-code.git
synced 2026-06-22 16:25:51 +00:00
feat: 添加 GitHub 集成命令(issue、share、autofix-pr)
- /issue: 通过 gh CLI 创建 GitHub issue,支持标签/指派 - /share: 会话日志分享到 GitHub Gist,支持密钥脱敏 - /autofix-pr: 自动修复 CI 失败的 PR,进度追踪 - launchCommand: 共享命令启动器 Co-Authored-By: glm-5-turbo <zai-org@claude-code-best.win>
This commit is contained in:
16
src/commands/autofix-pr/skillDetect.ts
Normal file
16
src/commands/autofix-pr/skillDetect.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
import { existsSync } from 'node:fs'
|
||||
import { join } from 'node:path'
|
||||
|
||||
export function detectAutofixSkills(cwd: string): string[] {
|
||||
const candidates = [
|
||||
'AUTOFIX.md',
|
||||
'.claude/skills/autofix.md',
|
||||
'.claude/skills/autofix-pr/SKILL.md',
|
||||
]
|
||||
return candidates.filter(rel => existsSync(join(cwd, rel)))
|
||||
}
|
||||
|
||||
export function formatSkillsHint(skills: string[]): string {
|
||||
if (skills.length === 0) return ''
|
||||
return ` Run ${skills.join(' and ')} for custom instructions on how to autofix.`
|
||||
}
|
||||
Reference in New Issue
Block a user