github-tools / github-release-notes

Node module to create a release or a changelog from a tag and uses issues or commits to creating the release notes.
https://github-tools.github.io/github-release-notes/
GNU General Public License v3.0
880 stars 325 forks source link

Gren takes all PRs, not only the one between tags #305

Closed antoinewg closed 2 years ago

antoinewg commented 2 years ago

Hello, First thanks a lot for the tool, it's amazing. However I have a slight issue with it:

Here's my gren config file:

{
  "dataSource": "prs",
  "prefix": "",
  "onlyMilestones": false,
  "ignoreTagsWith": ["test", "hotfix", "deploy"],
  "groupBy": {
    "πŸ”₯ Enhancements:": ["enhancement", "feature"],
    "πŸ› Bug Fixes:": ["bug"],
    "βš™οΈ Tech:": ["tech"],
    "πŸ“œ Documentation:": ["documentation"]
  },
  "changelogFilename": "CHANGELOG.md",
  "template": {
    "issue": "- {{name}} [{{text}}]({{url}})"
  }
}

So basically I want to group the PRs between two tags for each release. The problem is that for each release it takes the information from all the PRs, and filter the one between the previous tag and the tag to release.

Let me explain with an example taken from this repo: https://github.com/antoinewg/smartlists.

From the commit log, we can see the commits:

However, when I launch gren release --tags=all --override, all releases (v1.0.1, v1.0.2, v1.0.3) have every PRs inside, and the first one v1.0.0 doesn't have any changelog.

Could you explain what I'm doing wrong ? Or how to "attach" a PR to a particular tag.

For more details, here's the repo on which I've tested it: https://github.com/antoinewg/smartlists/releases

Best regards, Antoine

antoinewg commented 2 years ago

Closing because when re-running the same command it works. It seems that it needs the releases to exists before being able to assigne a PR to a tag/release.