Skip to main content

CLI tools for viewing simple stats about files

Project description

stat-tools

A small collection of simple CLI utilities for displaying stats about sets of files. Currently stat-tools provides two utility commands, extat for showing statistics about path suffixes (aka file extensions), and imstat for displaying information about image files, e.g resolution, size, format etc.

Usage

Both commands function by reading a set of files, separated by newlines, to analyze from stdin. Neither command provides any filesystem search or filtering functionality; it is the responsibility of an external tool to generate the list of paths to analyze and pass it to the stat-tools command over stdin. This design decision greatly simplifies the implementation of stat-tools and affords users maximum flexibility and control.

The intended use pattern is using a filesystem search tool such as GNU find, fd, or in simple cases ls to generate a list of file paths which is then piped to the desired stat-tools command:

# Report statistics on all files under `/some/root/path`
find some/root/path -type f | extat

extat

extat provides statistics about the path suffixes (aka "file extensions") present in the input list. This includes the number of paths with the suffix, the total number of paths, analyzed, the percentage of all paths having the suffix, the total file size of all files having the suffix, and the portion of total set file size represented by the suffix

imstat

imstat works the same way extat does, but is designed to only process image files, e.g. jpeg files, and webp files, and instead of printing statistics about the path suffixes, it prints information about each file's image metadata, e.g. resolution and file size info

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

quik_stat-0.1.2.tar.gz (31.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

quik_stat-0.1.2-py3-none-any.whl (4.3 kB view details)

Uploaded Python 3

File details

Details for the file quik_stat-0.1.2.tar.gz.

File metadata

  • Download URL: quik_stat-0.1.2.tar.gz
  • Upload date:
  • Size: 31.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.5

File hashes

Hashes for quik_stat-0.1.2.tar.gz
Algorithm Hash digest
SHA256 9732c5c97fa7a8557c2323363f0e6d2d10e63609a067ed37cef33c108135bfb5
MD5 e2fa218b494fee4b0637e0be6e5240ae
BLAKE2b-256 d8b84e5818810f61966221a6c0c20c5eac549b8866e871644bb44c12a078b1cc

See more details on using hashes here.

File details

Details for the file quik_stat-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: quik_stat-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 4.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.5

File hashes

Hashes for quik_stat-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 094cbc178baba812f09c37999dad7a859110367614dd6285744c58177336279d
MD5 d3564262c9241a524f9bba5201bee226
BLAKE2b-256 2e49b87ced76525517a82599e088349ef8d5243c24d635b7a75f1d77bb147b6a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page