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

feat(config): support placing configuration inside pyproject.toml #147

Merged
merged 1 commit into from
Mar 31, 2023

Conversation

radusuciu
Copy link
Contributor

@radusuciu radusuciu commented Mar 10, 2023

Please see #146 for a description. Also please note that this isn't yet tested on an actual repository though if there's interest I can do that.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation (no code change)
  • Refactor (refactoring production code)
  • Other

Checklist:

  • My code follows the code style of this project.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@radusuciu radusuciu requested a review from orhun as a code owner March 10, 2023 03:27
@radusuciu radusuciu force-pushed the pyproject-metadata branch from 0797bfa to 061b0b3 Compare March 10, 2023 17:34
@radusuciu radusuciu force-pushed the pyproject-metadata branch from 061b0b3 to 64f29ab Compare March 10, 2023 17:55
@orhun
Copy link
Owner

orhun commented Mar 11, 2023

Hello @radusuciu, thanks for the contribution! 🐻

Also please note that this isn't yet tested on an actual repository though if there's interest I can do that.

Can you please do that and post results? I think it should work just fine but let's see if there are any sharp edges.

@codecov-commenter
Copy link

Codecov Report

Patch coverage: 40.00% and project coverage change: +0.11 🎉

Comparison is base (0e710c2) 43.37% compared to head (64f29ab) 43.48%.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #147      +/-   ##
==========================================
+ Coverage   43.37%   43.48%   +0.11%     
==========================================
  Files          12       12              
  Lines         558      559       +1     
==========================================
+ Hits          242      243       +1     
  Misses        316      316              
Flag Coverage Δ
unit-tests 43.48% <40.00%> (+0.11%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
git-cliff-core/src/config.rs 40.00% <40.00%> (-1.66%) ⬇️

... and 1 file with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@radusuciu
Copy link
Contributor Author

Hi, thanks for being open with contributions!

Yes, I will test this on some of my projects and update here.

@orhun
Copy link
Owner

orhun commented Mar 17, 2023

Looking forward to it!

@radusuciu
Copy link
Contributor Author

So I tested with a small project of mine and it works as expected in that it produces the same output given a --config pyproject.toml option as when the same configuration is specified in a cliff.toml. However, since I don't adhere to conventional commits in that project, for reasons that I don't fully understand my commit messages aren't showing (both with pyproject.toml and cliff.toml) even though I used the configuration described in the README. So for that reason, I did not commit a changelog.

I tested with a second repository, this time with the PDM project. For my fork, see the following files:

Though I am not yet very familiar with git-cliff, it seems to me that the code in this PR works as intended, though I'm happy to test further if you'd like.

Thanks!

@radusuciu
Copy link
Contributor Author

FYI, confirmed working on another project! See pyproject.toml and the generated CHANGELOG. All seems to be working as intended.

Copy link
Owner

@orhun orhun left a comment

Choose a reason for hiding this comment

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

Sounds great. Thank you for the PR and detailed testing! 🐻💖

@orhun orhun merged commit fe5e5b8 into orhun:main Mar 31, 2023
@radusuciu
Copy link
Contributor Author

Awesome, thank you!

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.

3 participants