mirror of
https://github.com/anthropics/claude-code-action.git
synced 2026-01-22 22:44:13 +08:00
Branch names containing special characters (particularly parentheses) were breaking markdown links in GitHub comments. This caused URLs to be truncated when clicked. Changes: - Add encodeBranchName() helper function that: - Uses encodeURIComponent for basic encoding - Preserves forward slashes (GitHub expects literal / in branch URLs) - Manually encodes parentheses (not encoded by encodeURIComponent per RFC 3986) - Apply encoding to branch URLs in: - update-comment-link.ts (PR compare URLs) - branch-cleanup.ts (branch tree URLs) - comment-logic.ts (branch tree URLs) - comments/common.ts (branch tree URLs) - Improve PR link regex to use greedy match with end anchor - Add test for branch names with special characters