Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: improve pull request workflows #1737

Merged

Conversation

juliapampus
Copy link
Contributor

@juliapampus juliapampus commented Jul 25, 2022

What this PR changes/adds

Add new regex that is more restrictive. PR titles have to match the conventional commit prefixes. Add label checker.

Why it does that

Improve PR quality. Label check was suggested in #1728.

Further notes

...

Linked Issue(s)

Relates #1719

Checklist

  • added appropriate tests?
  • performed checkstyle check locally?
  • added/updated copyright headers?
  • documented public classes/methods?
  • added/updated relevant documentation?
  • added relevant details to the changelog? (skip with label no-changelog)
  • formatted title correctly? (take a look at the CONTRIBUTING and styleguide for details)

@juliapampus juliapampus changed the title chore: enforce conventional commits example: enforce conventional commits Jul 25, 2022
@juliapampus juliapampus force-pushed the chore/enforce_conventional_commits branch 3 times, most recently from 1870c06 to 2472cfb Compare July 25, 2022 12:06
@juliapampus juliapampus changed the title example: enforce conventional commits Chore: enforce conventional commits Jul 25, 2022
@juliapampus juliapampus changed the title Chore: enforce conventional commits chore: enforce conventional commits Jul 25, 2022
@codecov-commenter
Copy link

codecov-commenter commented Jul 25, 2022

Codecov Report

Merging #1737 (26bc38f) into main (9e037d2) will decrease coverage by 56.78%.
The diff coverage is n/a.

❗ Current head 26bc38f differs from pull request most recent head 8021696. Consider uploading reports for the commit 8021696 to get more accurate results

@@              Coverage Diff              @@
##               main    #1737       +/-   ##
=============================================
- Coverage     67.34%   10.55%   -56.79%     
- Complexity        0      475      +475     
=============================================
  Files           785      785               
  Lines         16859    16858        -1     
  Branches       1061     1061               
=============================================
- Hits          11353     1779     -9574     
- Misses         5050    14995     +9945     
+ Partials        456       84      -372     
Impacted Files Coverage Δ
...eclipse/dataspaceconnector/spi/result/Failure.java 0.00% <0.00%> (-100.00%) ⬇️
...clipse/dataspaceconnector/spi/query/SortOrder.java 0.00% <0.00%> (-100.00%) ⬇️
...pse/dataspaceconnector/spi/event/EventPayload.java 0.00% <0.00%> (-100.00%) ⬇️
...e/dataspaceconnector/spi/query/QueryValidator.java 0.00% <0.00%> (-100.00%) ⬇️
...dataspaceconnector/spi/observe/ObservableImpl.java 0.00% <0.00%> (-100.00%) ⬇️
...taspaceconnector/spi/event/asset/AssetCreated.java 0.00% <0.00%> (-100.00%) ⬇️
...taspaceconnector/spi/event/asset/AssetDeleted.java 0.00% <0.00%> (-100.00%) ⬇️
...paceconnector/common/stream/PartitionIterator.java 0.00% <0.00%> (-100.00%) ⬇️
...paceconnector/spi/command/BoundedCommandQueue.java 0.00% <0.00%> (-100.00%) ⬇️
...connector/boot/util/CyclicDependencyException.java 0.00% <0.00%> (-100.00%) ⬇️
... and 522 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9e037d2...8021696. Read the comment docs.

@juliapampus juliapampus added the build Anything related to the CI/CD Pipeline on Github Actions label Jul 25, 2022
@juliapampus juliapampus force-pushed the chore/enforce_conventional_commits branch from 26bc38f to 8021696 Compare July 25, 2022 12:27
@juliapampus juliapampus changed the title chore: enforce conventional commits chore: improve pull request workflows Jul 25, 2022
@juliapampus juliapampus removed the build Anything related to the CI/CD Pipeline on Github Actions label Jul 25, 2022
- uses: actions/checkout@v3
- uses: agilepathway/label-checker@v1.0.113
with:
any_of: api,bug,build,dependencies,documentation,enhancement,ids,java,no-changelog,policy,refactoring
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would propose to choose the labels based on which categories we want to see in the changelog.
e.g. currently now there are only Bugfixes (bug), Documentation (documentation) and New Features & Improvements (*).
I would keep bug, documentation, enhancement (that could be used for new features), no-changelog.
maybe also api, dependencies and refactoring (that could be added as categories in the changelog task configuration)
but I would avoid the others (build, ids, java, policy).

Makes sense?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes.. the problem is that there is no action that allows wildcards, so e.g. changes to the pipeline would need the build label as no PRs with 0 labels are allowed. Maybe just skip ids, java, policy as this is too specific? The other ones kind of match the conventional commits prefixes.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would suggest to take a look at adding further categories to the changelog later.. first step is to have labels.

@juliapampus juliapampus force-pushed the chore/enforce_conventional_commits branch from 8021696 to 24efb38 Compare July 25, 2022 13:16
Copy link
Member

@ndr-brt ndr-brt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good for me

@juliapampus juliapampus merged commit 17f28f7 into eclipse-edc:main Jul 25, 2022
@juliapampus juliapampus deleted the chore/enforce_conventional_commits branch July 25, 2022 14:34
diegogomez-zf pushed a commit to diegogomez-zf/DataSpaceConnector that referenced this pull request Aug 3, 2022
* chore: improve restriction of PR title (define prefixes)

* chore: add check for labels
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants