Skip to content

Commit

Permalink
Prefix task ID in branch
Browse files Browse the repository at this point in the history
  • Loading branch information
bserem committed Oct 3, 2024
1 parent 8367a23 commit 9305f9c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions commands/host/branch
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,9 @@ def main():

# Create the branch name in the format YEAR/MONTH/ID-description (without the extra dash if no description)
if custom_text:
branch_name = f"{current_year}/{current_month:02}/{task_id}__{custom_text}"
branch_name = f"{current_year}/{current_month:02}/T-{task_id}__{custom_text}"
else:
branch_name = f"{current_year}/{current_month:02}/{task_id}"
branch_name = f"{current_year}/{current_month:02}/T-{task_id}"

# Ensure only valid characters are in the branch name
branch_name = "".join(c for c in branch_name if c.isalnum() or c in ['-', '_', '.', '/'])
Expand Down

0 comments on commit 9305f9c

Please sign in to comment.