Skip to main content

STATS CLI

A simple command line tool to analyze programming projects and display basic statistics about languages and files they contain.

Features

  • Analyxe one or more project directories at the same time.
  • Analyze folders containing multiple projects.
  • Count the total number of files.
  • Count the total number of lines.
  • Show how many projects use each language.
  • Recursively scan project directories.

Supported languges

The following table shows which extensions are currently recognized.

Extension
.py
.js
.html
.css
.java
.ts
.tsx
.jsx
.scss
.c
.h
.cpp
.cs
.go
.rs
Others

Instalation

Option 1

pip install stats-project-analyzer==0.2.0

Option 2

Clone the repository and install the project in editable mode.

git clone https://github.com/asierpernias/Stats.git
cd Stats
python -m pip install -e .

Depending on your operating system, you may need to take extra steps to make the stats command available in every terminal

Usage

Analyze the current directory

stats / stats .

Analyze a directory containig multiple projects

stats path/to/folder

Each subdirectory is treated as a separated project.

Analyze multiple directories

stats path/to/folder1 path/to/folder2

Analyze one or more individual projects

Use the -m option;

stats -m path/to/project

Or analyze multiple projects at the same time

stats -m path/to/project1 path/to/project2

Show help

stats --help

Example output

STATS: ------------------------------------------------ Files: 5 Lines: 150

Python 2 Js 1 Html 1 CSS 1 Java 0 Others 0

Requirements

  • Python 3.11 or newer
  • pip

The project uses setuptools for packaging and exposes the stats command through pyproject.toml

Screenshots

image

License

This project is licensed under the MIT Licnese.

Metadata

Release files for stats-project-analyzer 0.2.2

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

Source distribution (sdist)

Source distribution for stats-project-analyzer 0.2.2
File Size Uploaded Provenance Actions
stats_project_analyzer-0.2.2.tar.gz 6.1 kB Without provenance Details for stats_project_analyzer-0.2.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for stats-project-analyzer 0.2.2
File Interpreter ABI Platform Actions
stats_project_analyzer-0.2.2-py3-none-any.whl Python 3 none any Details for stats_project_analyzer-0.2.2-py3-none-any.whl

Total release size: 12.4 kB

Release files / stats_project_analyzer-0.2.2.tar.gz

Download URL stats_project_analyzer-0.2.2.tar.gz
Size 6.1 kB
Tags Source
SHA-256 checksum
How to use checksums
f818b24a76879929f0dd23ed55a9587d604b0c03040603fb792d181f1ab71b27
BLAKE2b-256 checksum
How to use checksums
5745abbf8cb478c5e84f3a833429f88710b080ccab22e6d9d2b2fbe521408e99
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.9

Release files / stats_project_analyzer-0.2.2-py3-none-any.whl

Download URL stats_project_analyzer-0.2.2-py3-none-any.whl
Size 6.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
845ffc49956b9e72703cf62e6e98d145b0447a0b8cdeb42c1c31c47efde2df28
BLAKE2b-256 checksum
How to use checksums
5453bf201a5cf9150fb928c3c6af81d2dcb5800f900fa68842005eed2767712a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.9

Security for stats-project-analyzer 0.2.2

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.

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