Skip to content

Commit

Permalink
include linked discussions and pull requests
Browse files Browse the repository at this point in the history
  • Loading branch information
falkoschindler committed Oct 6, 2023
1 parent 725a1f9 commit a155fb3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fetch_milestone.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
user: str = issue['user']['login']
body: str = issue['body']
labels: list[str] = [label['name'] for label in issue['labels']]
number_patterns = [r'#(\d+)', r'https://github.com/zauberzeug/nicegui/issues/(\d+)']
number_patterns = [r'#(\d+)', r'https://github.com/zauberzeug/nicegui/(?:issues|discussions|pulls)/(\d+)']
numbers = [issue['number']] + [int(match) for pattern in number_patterns for match in re.findall(pattern, body)]
numbers_str = ', '.join(f'#{number}' for number in sorted(numbers))
note = f'{title.strip()} ({numbers_str} by @{user})'
Expand Down

0 comments on commit a155fb3

Please sign in to comment.