Skip to content

Implements JSON output support#2

Merged
boblangley merged 1 commit intomainfrom
json-output-support
Dec 8, 2025
Merged

Implements JSON output support#2
boblangley merged 1 commit intomainfrom
json-output-support

Conversation

@boblangley
Copy link
Contributor

No description provided.

@boblangley boblangley self-assigned this Dec 8, 2025
@boblangley boblangley added the enhancement New feature or request label Dec 8, 2025
@boblangley boblangley requested a review from Copilot December 8, 2025 01:30
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR implements JSON output support for the MinVer CLI tool, allowing users to retrieve version information in machine-readable JSON format alongside the existing text format.

Key Changes:

  • Added --format CLI argument to support both text and JSON output formats
  • Made core data structures serializable by adding serde::Serialize derive macros
  • Implemented JSON formatting that includes all version components and calculation metadata

Reviewed changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
crates/core/src/version.rs Added Serialize derive to Version struct for JSON serialization support
crates/core/src/lib.rs Added Serialize derive to CalculationResult struct for JSON output
crates/core/Cargo.toml Added serde dependency with derive features
crates/cli/src/main.rs Implemented OutputFormat enum and JSON output logic with format selection
crates/cli/Cargo.toml Added serde_json and serde dependencies for JSON serialization
crates/cli/tests/cli.rs Added integration test verifying JSON output format and content

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@boblangley boblangley merged commit c4bbb2a into main Dec 8, 2025
1 check passed
@boblangley boblangley deleted the json-output-support branch December 8, 2025 18:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant