Skip to content

Complete refactoring, from a prime example of overengineering - #8

Merged
alexaandru merged 1 commit into
mainfrom
even-simpler
Aug 28, 2025
Merged

Complete refactoring, from a prime example of overengineering#8
alexaandru merged 1 commit into
mainfrom
even-simpler

Conversation

@alexaandru

Copy link
Copy Markdown
Owner

the LOC is down from 8748 -> 1004, while maintaining same level of code coverage & retaining 90% of functionality (only caching was removed).

Caching was dropped as the expected use cases are mostly in CI, checking for 1-10? releases so caching would hardly ever be useful.

Also, added a bit of colors. And a command to generate a SVG badge for a product release (appropriately color coded based on EOL, EOAS or MAINTAINED).

Copilot AI review requested due to automatic review settings August 28, 2025 11:11

Copilot AI left a comment

Copy link
Copy Markdown

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 represents a complete refactoring of the project, significantly reducing lines of code from 8,748 to 1,004 while maintaining code coverage and 90% of functionality. Caching was removed as the expected CI use cases involve checking only 1-10 releases, where caching would rarely be beneficial. Additionally, the refactor introduces color output and a new command to generate color-coded SVG badges for product releases based on EOL/EOAS/MAINTAINED status.

  • Massive code reduction from 8,748 to 1,004 lines while maintaining functionality
  • Removal of caching system due to limited utility in CI environments
  • Addition of colored output and SVG badge generation capability

Reviewed Changes

Copilot reviewed 89 out of 98 changed files in this pull request and generated 3 comments.

File Description
util.go New utility functions for version variants, duration parsing, URL building, JSON formatting, and other core utilities
util_test.go Comprehensive test coverage for all utility functions with parallel test execution
testdata/handle/* Test output files showing the application's various command outputs and API responses
testdata/golden/* Golden test files containing expected API response formats
Comments suppressed due to low confidence (1)

util.go:1

  • The panic recovery assumes that the recovered value r is always an error type. If the panic contains a non-error value (like a string), this will cause a runtime panic during the type assertion r.(error).
package main

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread util.go
Comment thread util.go
Comment thread util_test.go
the LOC is down from 8748 -> 1004, while maintaining same level of
code coverage & retaining 90% of functionality (only caching
was removed).

Caching was dropped as the expected use cases are mostly in CI,
checking for 1-10? releases so caching would hardly ever
be useful.

Also, added a bit of colors. And a command to generate a SVG
badge for a product release (appropriately color coded based
on EOL, EOAS or MAINTAINED).
@alexaandru
alexaandru merged commit 9f42607 into main Aug 28, 2025
4 checks passed
@alexaandru
alexaandru deleted the even-simpler branch August 28, 2025 11:32
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