Skip to main content

Tiny CLI that counts file types by extension and exports Markdown table or JSON.

Project description

file-type-counter-max

A tiny CLI that counts file types by extension in a folder, then exports a copy/paste-ready Markdown table or machine-parseable JSON summary. Built for repo audits, onboarding handoffs, cleanup reviews, and tech-mix discovery.

Install

Requires Python 3.11 or newer.

python3 -m pip install --user file-type-counter-max

Or install from source:

git clone https://github.com/<your-org>/file-type-counter-max.git
cd file-type-counter-max
python3 -m pip install --user .

After install, the command is file-type-counter-max.

Usage

file-type-counter-max /path/to/repo
file-type-counter-max .
file-type-counter-max /path/to/repo --format json
file-type-counter-max /path/to/repo --format markdown --min-count 2

Options

  • path: target directory to scan; defaults to the current directory.
  • -f, --format: output mode; table for human-readable Markdown table, json for machine-readable JSON.
  • -d, --depth: maximum directory depth to recurse into; omit for unlimited depth.
  • --min-count: only include extensions with at least this many files.
  • -i, --ignore: comma-separated folder basenames to skip, such as .git, node_modules, __pycache__.
  • --sort: sort order; count shows highest first, ext shows alphabetical by extension.
  • --help: show help message.

Output examples

Markdown table

| Extension | Count | Share |
| --- | ---: | ---: |
| .py | 181 | 54.0% |
| .toml | 42 | 12.6% |
| .md | 31 | 9.3% |
| .yml | 21 | 6.3% |

Sample run

Actual run against this repo with default table output:

| Extension | Count | Share |
| --- | ---: | ---: |
| .txt | 6 | 18.2% |
| (no extension) | 5 | 15.2% |
| .md | 4 | 12.1% |
| .pyc | 4 | 12.1% |
| .toc | 4 | 12.1% |
| .py | 3 | 9.1% |
| .html | 1 | 3.0% |
| .pkg | 1 | 3.0% |
| .pyz | 1 | 3.0% |
| .spec | 1 | 3.0% |
| .tag | 1 | 3.0% |
| .toml | 1 | 3.0% |
| .zip | 1 | 3.0% |

Release path

This project ships a single-command local install. For a ready-to-run release without an install step, use GitHub Releases or package it with pyinstaller or shiv.

Notes

  • This CLI avoids paid dependencies and does not collect telemetry.
  • Favorites or defaults are not stored; every run is computed fresh from the provided path.

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

file_type_counter_max-0.1.0.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

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

file_type_counter_max-0.1.0-py3-none-any.whl (6.2 kB view details)

Uploaded Python 3

File details

Details for the file file_type_counter_max-0.1.0.tar.gz.

File metadata

  • Download URL: file_type_counter_max-0.1.0.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.5

File hashes

Hashes for file_type_counter_max-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2a99d0da5f5bcc7ccf805a0b2f9fa216bb44f58ac6f3b8d2f2a551ee0190f203
MD5 2a9327edcb47ef883b787bc63ca56972
BLAKE2b-256 008160bf0a6d7bc20ca96d84de1c0413ed1d5b9fbaf6353a288eba60a6d8a804

See more details on using hashes here.

File details

Details for the file file_type_counter_max-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for file_type_counter_max-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 827c15bf28b7715d53b65777fcca996ddaa41c1e7ff7900c081ea6053be61152
MD5 80d1634ab62249ebbfd2f1a63d832591
BLAKE2b-256 4e5346ed5d10e86c2b7b9ac2be4e26bbb81fccd92c4fc418e561498ba418d378

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