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

refactor: initialize config structs with default values #1090

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Cyclonit
Copy link
Contributor

@Cyclonit Cyclonit commented Mar 12, 2025

Description

This change uses the embedded configuration to initialize configuration options with default values whenever possible. This moves the concern of defining default values into the embedded config and reduces complexity when using the configuration.

Motivation and Context

Implements #1087.

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.

@codecov-commenter
Copy link

codecov-commenter commented Mar 12, 2025

Codecov Report

Attention: Patch coverage is 48.71795% with 20 lines in your changes missing coverage. Please review.

Project coverage is 41.82%. Comparing base (bf50336) to head (27896eb).

Files with missing lines Patch % Lines
git-cliff/src/lib.rs 0.00% 19 Missing ⚠️
git-cliff-core/src/changelog.rs 83.34% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1090      +/-   ##
==========================================
+ Coverage   41.42%   41.82%   +0.41%     
==========================================
  Files          21       21              
  Lines        1811     1803       -8     
==========================================
+ Hits          750      754       +4     
+ Misses       1061     1049      -12     
Flag Coverage Δ
unit-tests 41.82% <48.72%> (+0.41%) ⬆️

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.

🚀 New features to boost your workflow:
  • Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Cyclonit Cyclonit force-pushed the feat/initialize_config_structs_with_default_values branch 13 times, most recently from 562d54e to 2181485 Compare March 13, 2025 09:28
@Cyclonit Cyclonit force-pushed the feat/initialize_config_structs_with_default_values branch from 2181485 to 27896eb Compare March 13, 2025 09:33
@Cyclonit Cyclonit marked this pull request as ready for review March 13, 2025 11:26
@Cyclonit Cyclonit requested a review from orhun as a code owner March 13, 2025 11:26
@Cyclonit Cyclonit changed the title refactor: default to embeded config refactor: initialize config structs with default values Mar 13, 2025
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.

2 participants