github-release-notes icon indicating copy to clipboard operation
github-release-notes copied to clipboard

Can I group the issues by specific label instead of the first label?

Open liangweihua-rock opened this issue 6 years ago • 5 comments

I got following error when group by specific label, can I do it by any option? gren's version is 0.17.0

gren release --group-by "Type:Bug" --tags=v0.1.0..v0.2.0 --override

🤖  - Generate release notes:
===================================
✔ Releases found: 2
✔ Tags found: v0.2.0, v0.1.0
✔ Issues found: 63
The option for groupBy is invalid, please check the documentation

liangweihua-rock avatar Dec 05 '19 09:12 liangweihua-rock

Hello @liangweihua-rock groupBy is either label or an Object (which means you need the config file) see https://github-tools.github.io/github-release-notes/options.html#group-by-1

alexcanessa avatar Dec 12 '19 10:12 alexcanessa

Hello @liangweihua-rock groupBy is either label or an Object (which means you need the config file) see https://github-tools.github.io/github-release-notes/options.html#group-by-1

Thanks a lot for your reply, I've tried the config file in the format of https://github-tools.github.io/github-release-notes/options.html#group-by-1, seems the issues is grouped by Label1 OR label2, i.e I want to group the issue with label1 AND label2 in one group, but seems all the issues with lable1 OR label2 are grouped in. I'll try it further.

liangweihua-rock avatar Dec 18 '19 02:12 liangweihua-rock

@liangweihua-rock oh I see what you mean.

We don't have any logic for that atm. Have you thought of a possible API for it?

alexcanessa avatar Dec 18 '19 10:12 alexcanessa

@liangweihua-rock oh I see what you mean.

We don't have any logic for that atm. Have you thought of a possible API for it?

Yes...I hope there would be an API to group the label1 AND label2, but I am not familar with javascript, I am in learning process.

liangweihua-rock avatar Dec 19 '19 00:12 liangweihua-rock

@liangweihua-rock I think we could use Arrays for that.

Something like this would group under the group Enhancements, the issues that have (enhancement AND new feature) OR internal.

{
    "groupBy": {
        "Enhancements:": [["enhancement", "new feature"], "internal"]
    }
}

alexcanessa avatar Dec 23 '19 10:12 alexcanessa