Skip to content

Commit e20d79e

Browse files
localdenCopilot
andauthored
Update scripts/powershell/create-new-feature.ps1
Co-authored-by: Copilot <[email protected]>
1 parent a26ee57 commit e20d79e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

scripts/powershell/create-new-feature.ps1

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,9 @@ try {
9797
if ($LASTEXITCODE -eq 0) {
9898
foreach ($branch in $branches) {
9999
# Clean branch name: remove leading markers and remote prefixes
100+
# The following regex removes:
101+
# - Git's current branch marker ('*') and leading whitespace (e.g., '* main')
102+
# - Remote prefixes (e.g., 'remotes/origin/')
100103
$cleanBranch = $branch.Trim() -replace '^\*?\s+', '' -replace '^remotes/[^/]+/', ''
101104

102105
# Extract feature number if branch matches pattern ###-*

0 commit comments

Comments
 (0)