Skip to content

Commit

Permalink
scripts: Update rgh.py
Browse files Browse the repository at this point in the history
  • Loading branch information
gavv committed Nov 26, 2024
1 parent ecd0d97 commit 61ac37a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/rgh.py
Original file line number Diff line number Diff line change
Expand Up @@ -641,8 +641,8 @@ def reword_pr_commits(org, repo, pr_number, title, no_issue):
f" -e '1s,^.*$,{commit_prefix}{title},'"
else:
sed = f"sed -r"+\
f" -e '1s,^(gh-[0-9]+:? +|{org}/[^ ]+ +|[Ii]ssue *[0-9]+:? +)?,{commit_prefix},'"+\
f" -e '1s,\s*\(?#[0-9]+\)?$,,'"
f" -e '1s,^(gh-[0-9]+:? *|#[0-9]+:? *|{org}/[^ ]+ *|[Ii]ssue *[0-9]+:? *)?,{commit_prefix},'"+\
f" -e '1s,\s*\(?#[0-9]+\)?$,,'"

run_cmd([
'git', 'filter-branch', '-f', '--msg-filter', sed,
Expand Down

0 comments on commit 61ac37a

Please sign in to comment.