size‑cmp
A lightweight tool to compare the size of two directories or files.
📦 Installation
# Clone the repository
git clone https://github.com/youruser/size-cmp.git
cd size-cmp
# Install dependencies (ruff, typer, flask, etc.)
python -m pip install -r requirements.txt
Note: The repository already contains a
deps/directory with bundled binaries (dust,file,size). The installer automatically adds this directory toPATHat runtime, so no extra system‑wide installation is required.
🚀 Quick start (Web UI)
# Run the web server (default host 0.0.0.0, port 5002)
size-cmp web /path/to/dirA /path/to/dirB
Open your browser and navigate to http://localhost:5002. The UI displays a tree view of the two directories, colour‑coded differences, and on‑demand file‑detail comparison.
Options
| Option | Description |
|---|---|
--host |
Bind address (default: 0.0.0.0) |
--port |
Port number (default: 5002) |
--debug |
Enable Flask debug mode |
💻 CLI usage (top command)
The tool provides a top sub‑command that lists the biggest differences between two directories.
# Show the top 10 biggest differences
size-cmp top /path/to/dirA /path/to/dirB -n 10
# Output as JSON (useful for scripts)
size-cmp top /path/to/dirA /path/to/dirB -n 10 --json
Options
| Option | Description |
|---|---|
-n, --top |
Number of entries to display (default: 10) |
--json |
Print a machine‑readable JSON object instead of a table |
--host / --port |
Same as the web command – only needed when you also want to start the web UI from the same invocation |
🛠️ Advanced configuration
- Binary dependencies – The
deps/folder contains the required binaries (dust,file,size). They are automatically added toPATHwhenapp.pystarts, so the tool works on any Linux host without installing these utilities globally. - Git metadata – The repository’s Git author/committer information has been normalised to
skyfire <skyfireitdiy@hotmail.com>.
📚 License
MIT License – see the LICENSE file for details.
🌐 Internationalization
- English README: This file (
README.md). - 中文 README: See the companion file
README.zh.mdfor Chinese documentation.
📚 License
MIT License – see the LICENSE file for details.
Metadata
Release files for size-cmp 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| size_cmp-0.1.3.tar.gz | 7.5 kB | Without provenance | Details for size_cmp-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| size_cmp-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for size_cmp-0.1.3-py3-none-any.whl |
Total release size: 15.3 kB
Release files / size_cmp-0.1.3.tar.gz
| Download URL | size_cmp-0.1.3.tar.gz |
|---|---|
| Size | 7.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
15c9d00431147f58e79c0c078f47d68593246bddb6cbe1f739ab45e216199c75
|
|
BLAKE2b-256 checksum How to use checksums |
c235f1408ae09399b80864acd767c2e0ccb120da137c469abf619f9a965c3d14
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.15
|
Release files / size_cmp-0.1.3-py3-none-any.whl
| Download URL | size_cmp-0.1.3-py3-none-any.whl |
|---|---|
| Size | 7.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7e4dc3c778607c5f5f9266c7e0e922055e6062887bb07178abca872049497fae
|
|
BLAKE2b-256 checksum How to use checksums |
011779db770cbf7fdee86768274968b6b1179165a003b13442421738bcb66def
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.11.15
|
Security for size-cmp 0.1.3
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.