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(bump): support bumping to a specific semver type #744

Merged
merged 6 commits into from
Jul 31, 2024

Conversation

braineo
Copy link
Contributor

@braineo braineo commented Jul 5, 2024

Description

Support bumping to a specific semver type with --bump major/minor/patch

Motivation and Context

Allow user bumping the version by specifying the type including major, minor and patch

How Has This Been Tested?

Screenshots / Logs (if applicable)

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 formatted the code with rustfmt.
  • I checked the lints with clippy.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@braineo braineo requested a review from orhun as a code owner July 5, 2024 01:57
Copy link

welcome bot commented Jul 5, 2024

Thanks for opening this pull request! Please check out our contributing guidelines! ⛰️

@braineo braineo marked this pull request as draft July 5, 2024 01:57
@braineo
Copy link
Contributor Author

braineo commented Jul 5, 2024

hi @orhun this is still a experimental draft that i would like to see if the approach if right to add an option to specify the bump type before i add more tests and documentation

this change has similar effect of --release-as in standard-version cli

@codecov-commenter
Copy link

codecov-commenter commented Jul 5, 2024

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

Attention: Patch coverage is 17.24138% with 24 lines in your changes missing coverage. Please review.

Project coverage is 35.89%. Comparing base (35dc1e4) to head (309f953).
Report is 1 commits behind head on main.

Files Patch % Lines
git-cliff/src/args.rs 0.00% 15 Missing ⚠️
git-cliff-core/src/release.rs 45.46% 6 Missing ⚠️
git-cliff/src/lib.rs 0.00% 3 Missing ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #744      +/-   ##
==========================================
- Coverage   36.40%   35.89%   -0.51%     
==========================================
  Files          20       20              
  Lines        1522     1544      +22     
==========================================
  Hits          554      554              
- Misses        968      990      +22     
Flag Coverage Δ
unit-tests 35.89% <17.25%> (-0.51%) ⬇️

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

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

git-cliff-core/src/release.rs Outdated Show resolved Hide resolved
@braineo
Copy link
Contributor Author

braineo commented Jul 29, 2024

hi @orhun I wonder if you have taken a look at the pr and can provide some feedback on it. thanks!

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.

I like it, thanks for the PR! Had some comments.

git-cliff/src/args.rs Outdated Show resolved Hide resolved
git-cliff-core/src/release.rs Outdated Show resolved Hide resolved
@braineo braineo marked this pull request as ready for review July 30, 2024 01:25
@braineo
Copy link
Contributor Author

braineo commented Jul 30, 2024

@orhun Let me know what do you think : )

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.

LGTM! Can you add a fixture test as well? I'm guessing you can simply grab one of the test-bump-version ones and edit it accordingly.

@braineo
Copy link
Contributor Author

braineo commented Jul 31, 2024

LGTM! Can you add a fixture test as well? I'm guessing you can simply grab one of the test-bump-version ones and edit it accordingly.

No problem. Added.

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.

Neat.

@orhun orhun changed the title Support bumping to a specific semver type feat(bump): support bumping to a specific semver type Jul 31, 2024
@orhun orhun merged commit 9dbf47b into orhun:main Jul 31, 2024
58 checks passed
Copy link

welcome bot commented Jul 31, 2024

Congrats on merging your first pull request! ⛰️

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