feat(logging): establish logging framework with quiet mode #125
No reviewers
Labels
No labels
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
thwap/pget!125
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/logging"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
Create
internal/loggingpackage with a simple logger that wrapslogpackage. Support quiet mode (-qflag) to suppress non-error output.Why
Provides centralized logging for all modules — info messages suppressed in quiet mode, errors always visible.
Testing
go vet ./...passesgo build ./...passesgolangci-lint run ./...passesBreaking Changes
None
Notes
Logger.Print/Printf— silent when quiet=trueLogger.Error/Errorf— always printedQuiet bool, wired to-qflag andPGET_QUIETenv varPGET_QUIETenv var entryCloses #0020
Closes #0021
Closes #0022
Review: APPROVED
Verification
go vet ./...— ✅ passesgo build ./...— ✅ passesgolangci-lint v2 run ./...— ✅ 0 issues-h) — ✅ includes-qflag andPGET_QUIETenv varChanges
internal/logging/logging.go(new) — Logger wrappinglogwith quiet modeinternal/config/config.go— AddsQuiet bool,-qflag,PGET_QUIETenv varcmd/pget/main.go— Creates logger from configROADMAP.md— Marks logging items as [x]Suggestions (non-blocking)
Closes #0020, #0021, #0022 on merge.