feat(analyze): fix bugs in analyze mode - detect OrbStack, Gradle and Python caches#20
Merged
feat(analyze): fix bugs in analyze mode - detect OrbStack, Gradle and Python caches#20
Conversation
- Updated cleanup_test.sh to reduce test file sizes for faster execution. - Removed interactive_menu_test.sh as it was redundant and covered by smoke tests. - Added smoke_test.sh for critical end-to-end validations of CLI and interactive menu. - Enhanced analyze_mode_test.sh to streamline setup and teardown processes. - Optimized devtools_test.sh by removing placeholder tests and focusing on essential functionality. - Improved jetbrains_test.sh by reducing the number of mock installations for efficiency. - Added analyze mode detection tests in docker_test.sh and other relevant test files.
Owner
Author
|
It resolver issue #6 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🐛 Bug Fixes in Analyze Mode
Fixes #6
Problem
Demo revealed that analyze mode was missing ~9.3GB of cleanable caches:
Solution
Created
register_if_analyzing()helper function and fixed all 3 modules to properly detect caches in analyze mode.Changes Made
1. Helper Function (
src/utils/common.sh)register_if_analyzing()- encapsulates analyze-first pattern2. OrbStack Fix (
src/modules/docker.sh)docker_clean()3. Gradle Fix (
src/modules/devtools.sh)remove_outdated_gradle_caches()4. Python/pip Fix (
src/modules/devtools.sh)confirm_action()inclear_python_package_caches()5. Tests
docker_test.shanddevtools_test.sh6. Demo & Documentation
demo.tapeto show analyze detecting ~14GBREADME.mdwith demo GIF and analyze mode documentationsetup-demo.shto clarify 18GB created → 14GB cleanableResults
Before:
After:
+5GB detected (13GB vs 8GB before) ✨
Testing
$ make test Tests: 115 passed, 115 total Assertions: 153 passed, 153 total All tests passed Time taken: 12.80sChecklist