executablebooks / github-activity

Simple markdown changelogs for GitHub repositories
https://github-activity.readthedocs.io/en/latest/
BSD 3-Clause "New" or "Revised" License
47 stars 11 forks source link

Exclude PRs merged but not in releasing branch #50

Closed minrk closed 1 year ago

minrk commented 3 years ago

Is your feature request related to a problem? Please describe.

Not all merged PRs are merged into the currently to-be-released branch. It would be useful to include only those that are merged into the current branch.

Describe the solution you'd like

Specify a branch I am releasing from (default: current branch or repo default), and only include PRs that have been merged into that branch.

The simplest solution is to look at the base branch in the pr metadata. This, however, will not include multi-stage PRs (multiple PRs to a feature branch, which is later merged to main). It's a good start, though.

It is possible from the git graph, though, to determine exactly which PRs are ancestors to the current branch. That might be more work than we want to do, and can always be a second improvement later.

Additional context

I'm working on a jupyerhub release, and we currently have a long-running 'rbac' branch with merged PRs that are not being released. I have to manually remove those from the generated changelog.

In the future, though, I'd like all of those to be included as changelog items, rather than the one big rbac->main merge at the end.

welcome[bot] commented 3 years ago

Thanks for opening your first issue here! Engagement like this is essential for open source projects! :hugs:
If you haven't done so already, check out EBP's Code of Conduct. Also, please try to follow the issue template as it helps other community members to contribute more effectively.
If your issue is a feature request, others may react to it, to raise its prominence (see Feature Voting).
Welcome to the EBP community! :tada:

choldgraf commented 3 years ago

I think this is a good idea - agreed that we can go with an 80/20 principle here and focus on the low hanging fruit first!

blink1073 commented 3 years ago

cf https://github.com/executablebooks/github-activity/pull/42

minrk commented 1 year ago

closed by #42