github equationzhao/g v0.31.2

5 months ago

v0.31.2 Release Notes

New Features

  • -t flag for time-based sorting — Added -t as a shorthand flag to sort by modification time, complementing the existing --sort=time option for a quicker workflow

Performance Improvements

  • Iterative tree traversal (#272) — Replaced recursive directory tree traversal with an explicit stack-based iterative DFS, significantly reducing memory pressure and goroutine count in deep directory trees. Also refactored TreeBuilder/TreePrinter, added typed ParentPath/Level fields on FileInfo, and added unit tests
  • Adaptive batch processing strategy — Introduced intelligent strategy selection for directory processing:
    • Directories with < 50 files: uses traditional approach to avoid optimization overhead
    • Directories with ≥ 50 files: uses batch file processing for better throughput
    • JSON output: always uses traditional processing to prevent ~24% performance regression

Bug Fixes

  • fish shell path completion (#267) — Removed the -f flag from fish completions to fix broken path auto-completion in fish shell
  • Lint violations (#280) — Fixed remaining lint warnings across benchmarks, printers, and content helpers

Maintenance

  • Go 1.24.1 upgrade (#279) — Updated CI workflows and docs to use Go 1.24.1
  • go fix cleanup (#274) — Ran go fix to update deprecated API usage
  • Dependency bump (#287) — github.com/buger/jsonparser 1.1.1 → 1.1.2
  • Release workflow fixes (#286, #288) — Fixed dirty-file check failures and non-deterministic man page generation; release process now uses PRs for consistency

Full Changelog: v0.31.0...v0.31.2

Don't miss a new g release

NewReleases is sending notifications on new releases.