Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Aug 25, 2025

This PR fixes several issues with the omitVersions feature that were preventing it from working correctly with config files and causing documentation inconsistencies.

Issues Fixed

1. Missing Config Schema Field

The omitVersions field was missing from the config schema in schema.ts, which meant it couldn't be parsed from config files. Users could only use the CLI flag --omit-versions but not configure it in their config files.

2. Documentation Inconsistencies

  • The README.md showed "omitVersion" (singular) instead of the correct "omitVersions" (plural)
  • The CLI documentation was missing the --omit-versions flag entirely
  • Config file examples didn't show the omitVersions option

3. Testing Coverage

No end-to-end tests existed to validate that the omitVersions config file parsing worked correctly.

Changes Made

  1. Added omitVersions to config schema - Users can now use "omitVersions": true/false in their config files
  2. Fixed README documentation - Changed "omitVersion" to "omitVersions"
  3. Added CLI documentation - Documented the --omit-versions flag with usage examples
  4. Updated config file documentation - Added omitVersions examples in JSON, YAML, and JavaScript formats
  5. Added comprehensive tests - Created end-to-end tests to validate config file parsing works correctly

Before/After Example

Before (broken):

{
  "omitVersions": true  // This was ignored due to missing schema
}

After (working):

{
  "omitVersions": true  // Now properly parsed and applied
}

The output now correctly shows package names without versions (e.g., dep-one instead of [email protected]) when omitVersions is enabled via config file.

Fixes #635.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copy link
Contributor Author

Copilot AI commented Aug 25, 2025

@tobysmith568 👋 This repository doesn't have Copilot instructions. With Copilot instructions, I can understand the repository better, work faster and produce higher quality PRs.

I can generate a .github/copilot-instructions.md file for you automatically. Click here to open a pre-filled issue and assign it to me. I'll write the instructions, and then tag you for review.

Copilot AI changed the title [WIP] Omit Versions is documented & parsed incorrectly Fix omitVersions config parsing and documentation Aug 25, 2025
Copilot AI requested a review from tobysmith568 August 25, 2025 10:02
@codecov
Copy link

codecov bot commented Aug 25, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.83%. Comparing base (26c6fe9) to head (3301d42).
⚠️ Report is 15 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff             @@
##              main     #637      +/-   ##
===========================================
- Coverage   100.00%   99.83%   -0.17%     
===========================================
  Files           32       32              
  Lines          610      621      +11     
  Branches       103      106       +3     
===========================================
+ Hits           610      620      +10     
- Misses           0        1       +1     

☔ 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.

@tobysmith568 tobysmith568 marked this pull request as ready for review August 25, 2025 15:54
@tobysmith568 tobysmith568 merged commit c56c505 into main Aug 25, 2025
32 of 34 checks passed
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.

Omit Versions is documented & parsed incorrectly

2 participants