Skip to main content

tree_stat

Count files and their size in a directory tree with stats for each level.

Given a tree:

0_0_root/
├── 1_0_leaf
│   ├── bold-blackburn.txt
│   ├── funny-lederberg.txt
│   └── inspiring-kirch.blu
├── 1_1_node
│   ├── 2_0_leaf
│   │   ├── adoring-dhawan.mp4
│   │   ├── festive-haslett.html
│   │   ├── interesting-poincare.jpg
│   │   └── vigorous-hopper.blu
│   ├── 2_1_node
│   │   ├── 3_0_leaf
│   │   │   └── jolly-williamson.json
│   │   └── stoic-napier.jpg
│   ├── 2_2_node
│   │   ├── 3_0_node
│   │   │   ├── 4_0_leaf
│   │   │   │   ├── stupefied-kilby.json
│   │   │   │   └── thirsty-fermi.json
│   │   │   └── 4_1_leaf
│   │   ├── 3_1_node
│   │   │   └── 4_0_leaf
│   │   │       ├── nice-franklin.json
│   │   │       └── quirky-greider.blu
│   │   ├── goofy-bose.html
│   │   ├── keen-jones.blu
│   │   ├── nervous-edison.mp4
│   │   └── nifty-mendeleev.html
│   ├── naughty-wu.jpg
│   ├── pensive-minsky.mp3
│   └── sleepy-boyd.mp3
└── 1_2_node
    ├── 2_0_node
    │   └── 3_0_leaf
    │       ├── great-lewin.mp3
    │       └── romantic-northcutt.mp3
    ├── condescending-banach.jpg
    ├── modest-chandrasekhar.jpg
    ├── objective-mendel.blu
    └── zen-noyce.mp4

14 directories, 26 files

It produces:

directory type count size
0_0_root ALL 26 29.914 MiB
0_0_root .mp3 4 3.901 MiB
0_0_root .jpg 5 211.019 KiB
0_0_root .blu 5 9.829 MiB
0_0_root .html 3 549.206 KiB
0_0_root .mp4 3 15.357 MiB
0_0_root .json 4 64.902 KiB
0_0_root .txt 2 21.407 KiB
0_0_root/1_2_node ALL 6 12.852 MiB
0_0_root/1_2_node .jpg 2 53.018 KiB
0_0_root/1_2_node .mp4 1 7.573 MiB
0_0_root/1_2_node .blu 1 2.321 MiB
0_0_root/1_2_node .mp3 2 2.907 MiB
0_0_root/1_2_node/2_0_node ALL 2 2.907 MiB
0_0_root/1_2_node/2_0_node .mp3 2 2.907 MiB
0_0_root/1_2_node/2_0_node/3_0_leaf ALL 2 2.907 MiB
0_0_root/1_2_node/2_0_node/3_0_leaf .mp3 2 2.907 MiB
0_0_root/1_0_leaf ALL 3 1.588 MiB
0_0_root/1_0_leaf .txt 2 21.407 KiB
0_0_root/1_0_leaf .blu 1 1.567 MiB
0_0_root/1_1_node ALL 17 15.474 MiB
0_0_root/1_1_node .mp3 2 1018.227 KiB
0_0_root/1_1_node .jpg 3 158.001 KiB
0_0_root/1_1_node .blu 3 5.941 MiB
0_0_root/1_1_node .html 3 549.206 KiB
0_0_root/1_1_node .mp4 2 7.785 MiB
0_0_root/1_1_node .json 4 64.902 KiB
0_0_root/1_1_node/2_0_leaf ALL 4 3.698 MiB
0_0_root/1_1_node/2_0_leaf .jpg 1 55.229 KiB
0_0_root/1_1_node/2_0_leaf .mp4 1 1.282 MiB
0_0_root/1_1_node/2_0_leaf .blu 1 2.059 MiB
0_0_root/1_1_node/2_0_leaf .html 1 310.553 KiB
0_0_root/1_1_node/2_1_node ALL 2 60.127 KiB
0_0_root/1_1_node/2_1_node .jpg 1 51.771 KiB
0_0_root/1_1_node/2_1_node .json 1 8.355 KiB
0_0_root/1_1_node/2_1_node/3_0_leaf ALL 1 8.355 KiB
0_0_root/1_1_node/2_1_node/3_0_leaf .json 1 8.355 KiB
0_0_root/1_1_node/2_2_node ALL 8 10.673 MiB
0_0_root/1_1_node/2_2_node .blu 2 3.882 MiB
0_0_root/1_1_node/2_2_node .html 2 238.653 KiB
0_0_root/1_1_node/2_2_node .mp4 1 6.502 MiB
0_0_root/1_1_node/2_2_node .json 3 56.547 KiB
0_0_root/1_1_node/2_2_node/3_0_node ALL 2 34.133 KiB
0_0_root/1_1_node/2_2_node/3_0_node .json 2 34.133 KiB
0_0_root/1_1_node/2_2_node/3_0_node/4_1_leaf ALL 0 0 B
0_0_root/1_1_node/2_2_node/3_0_node/4_0_leaf ALL 2 34.133 KiB
0_0_root/1_1_node/2_2_node/3_0_node/4_0_leaf .json 2 34.133 KiB
0_0_root/1_1_node/2_2_node/3_1_node ALL 2 2.202 MiB
0_0_root/1_1_node/2_2_node/3_1_node .json 1 22.414 KiB
0_0_root/1_1_node/2_2_node/3_1_node .blu 1 2.180 MiB
0_0_root/1_1_node/2_2_node/3_1_node/4_0_leaf ALL 2 2.202 MiB
0_0_root/1_1_node/2_2_node/3_1_node/4_0_leaf .json 1 22.414 KiB
0_0_root/1_1_node/2_2_node/3_1_node/4_0_leaf .blu 1 2.180 MiB

Metadata

Release files for tree-stat 0.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for tree-stat 0.2.0
File Size Uploaded Provenance Actions
tree_stat-0.2.0.tar.gz 4.7 kB Without provenance Details for tree_stat-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for tree-stat 0.2.0
File Interpreter ABI Platform Actions
tree_stat-0.2.0-py3-none-any.whl Python 3 none any Details for tree_stat-0.2.0-py3-none-any.whl

Total release size: 10.3 kB

Release files / tree_stat-0.2.0.tar.gz

Download URL tree_stat-0.2.0.tar.gz
Size 4.7 kB
Tags Source
SHA-256 checksum
How to use checksums
0447069433703b7617e6362d076bfdd6f04c8d1d44ea1f9b72e649dfe8b64778
BLAKE2b-256 checksum
How to use checksums
29d458f7c7afe9bd4f7b4f35cd7eac8d0b3ee7b4da12749e0e4c2d73a6b37316
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.1

Release files / tree_stat-0.2.0-py3-none-any.whl

Download URL tree_stat-0.2.0-py3-none-any.whl
Size 5.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
44cdd098d6da6a8495f5d5e21c3391ea22f1a50c9d9d8cf8a0ba632fb066513d
BLAKE2b-256 checksum
How to use checksums
13a7471b8ed0982630dec3ed68d913b3a6bd5a92bb09af6cc3a86f3d767b3624
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.2 CPython/3.7.1

Security for tree-stat 0.2.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page