Releases: yangshun/tree-node-cli
Releases · yangshun/tree-node-cli
v3.0.0
What's New
New Features
- JSON output format (
-Jflag) — output directory tree as JSON - Gitignore support — respects
.gitignorepatterns by default - Full path prefix (
-fflag) — display full path for each entry - Prune empty directories (
--pruneflag) — remove empty directories from output - File permissions (
-pflag) — show file type and permissions - Last modification time (
-Dflag) — show last modification time for each entry - Quoted filenames (
-Qflag) — quote filenames in double quotes - No-indentation mode (
-iflag) — print entries without tree indentation lines - Disk usage (
--duflag) — show directory sizes as cumulative disk usage - All Linux tree sorting options — including version/natural sort (
-v) treeJson()API — programmatic JSON tree output
Improvements
- File size options now match Linux tree:
-sfor raw bytes,-hfor human-readable (1024-based),--sifor SI units (1000-based) - Permission errors handled gracefully, matching Linux tree behavior
- Refactored to tree-first architecture: build tree then format
- CLI options reordered to match Linux tree categories
- Test coverage improved from 80% to 98%
- Performance: cached
lstatSyncresults to avoid redundant syscalls
Breaking Changes
- File size flag behavior changed to match Linux tree (
-s,-h,--si) - Gitignore filtering is now enabled by default
- Requires Node.js >= 22
Full Changelog: v2.0.0...v3.0.0
v2.0.0
Breaking Changes
- Requires Node.js >= 22
- Migrated to TypeScript with ESM + CJS dual packaging
- Migrated CLI parser from Commander to cac
Changes
- Dropped
fast-folder-sizedependency - Added GitHub Actions CI
- Added
prepublishOnlyscript for safer publishing - Improved test coverage (symlinks, special characters, combined options, edge cases)
Internal
- Migrated from Jest to Vitest
- Migrated from Prettier to Oxfmt
- Added Oxlint for linting
- Build toolchain changed to tsdown
- Package manager changed to pnpm
v1.6.0
What's Changed
- Bump hosted-git-info from 2.8.8 to 2.8.9 by @dependabot[bot] in #26
- Bump lodash from 4.17.15 to 4.17.21 by @dependabot[bot] in #25
- Bump y18n from 4.0.0 to 4.0.1 by @dependabot[bot] in #24
- Bump ws from 7.3.1 to 7.4.6 by @dependabot[bot] in #27
- Bump tmpl from 1.0.4 to 1.0.5 by @dependabot[bot] in #29
- Bump path-parse from 1.0.6 to 1.0.7 by @dependabot[bot] in #28
-S,--line-asciioption by @KSR-Yasuda in #30- Add --sizes option by @marcofugaro in #31
New Contributors
- @KSR-Yasuda made their first contribution in #30
- @marcofugaro made their first contribution in #31
Full Changelog: v1.4.0...v1.6.0
v1.4.0
Full Changelog: v1.3.0...v1.4.0