fix: enable --show-item-count in non-interactive mode (#431)#495
Merged
dundee merged 2 commits intodundee:masterfrom Feb 24, 2026
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #495 +/- ##
==========================================
+ Coverage 81.42% 81.54% +0.11%
==========================================
Files 49 49
Lines 5126 5158 +32
==========================================
+ Hits 4174 4206 +32
Misses 816 816
Partials 136 136 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Contributor
Author
|
Addressed the Codecov patch-coverage gaps with targeted tests and pushed commit What was added:
Validation run locally:
Please re-check Codecov on this latest head. |
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.
Problem
The
--show-item-count(-C) flag was not working in non-interactive mode (-n). Item counts were not displayed next to entries, unlike in interactive mode.Solution
stdout/stdout.goto respect the--show-item-countflag in non-interactive outputcmd/gdu/app/app.goto properly pass the item count flag to the stdout formatterstdout/stdout_test.goto verify item counts display correctly in non-interactive modeTesting
All tests pass:
golangci-lint run✓go test -v -covermode=count ./...✓go test -v -race -covermode=atomic -coverprofile=coverage.out ./...✓Closes
Closes #431