Repository navigation
Fix generated branch names containing invalid dot sequences - #80
Merged
Merged
Conversation
Dots in issue titles (e.g. trailing "...") produced branch names with ".." or trailing ".", which Git rejects. Strip all trailing dots with TrimRight instead of only one with TrimSuffix, and exclude dots from the allowed-character regex so they are replaced like other punctuation. Fixes #23 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Reviewer's GuideUpdates branch-name sanitization so dots are treated as punctuation and all trailing dots are removed, preventing invalid Git refs, with focused regression tests for trailing, embedded, and dot-only title inputs. File-Level Changes
Assessment against linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
Truncating a generated branch name at maxLen could leave a trailing hyphen. Trim it so the result is always clean. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
...) produced branch names with..or trailing., which Git rejects as invalid ref names.TrimSuffixtoTrimRightso all trailing dots are stripped, not just one..from the allowed-character regex so dots are replaced with-like other punctuation.Fixes #23
Test plan
"Collect metrics for issues, pull requests, ...")"Fix v2.0 regression")"...")🤖 Generated with Claude Code
Summary by Sourcery
Generate Git-valid branch names from titles containing dots and punctuation.
Bug Fixes:
Enhancements:
Tests: