Skip to main content

Count lines of Python code in directories

Project description

Countsy 📏

A fast, customizable line counter for Python projects (with plans to expand!)

Features ✨

  • Count lines in Python files (with more languages coming soon!)
  • Flexible filtering: Ignore comments, blank lines, or both
  • Progress bars (optional) for large directories
  • Faster than cloc for pure Python projects

Installation ⚡

pip install countsy

Usage 🚀

Basic Command

countsy /path/to/folder  # Default: current directory

Sample Output

  Total Python-Files in current directory: 7
  Total lines in folder:  471

Flags 🎛️

Flag Description Default
--tqdm Show progress bar False
--ignore-comments Exclude single/multi-line comments False
--ignore-blank-lines Exclude empty lines False
--ignore Exclude both comments and blank lines False

Example

countsy /path/to/folder --ignore --tqdm

Disclaimer⚠️

  • tqdm is required for progress bars

Missing Modules? 🔧

# Install required dependencies
pip install tqdm

Roadmap 🗺️

  • Support for more languages (JavaScript, Java, etc.)
  • Optimize speed for large codebases
  • Optional dependencies

Contributing 🤝

PRs and feature requests are welcome!

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

countsy-1.0.8.tar.gz (5.8 kB view details)

Uploaded Source

Built Distribution

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

countsy-1.0.8-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file countsy-1.0.8.tar.gz.

File metadata

  • Download URL: countsy-1.0.8.tar.gz
  • Upload date:
  • Size: 5.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.0

File hashes

Hashes for countsy-1.0.8.tar.gz
Algorithm Hash digest
SHA256 76461af56893016bea7f87abab254ad383f8e49dddf86baa7870198c680a9b48
MD5 6b7a9e796239c1ca36ce14b147e9a45c
BLAKE2b-256 330c65e494d5270ad24a0c85d3d2dde44afdfe58996ad317834e608bc74ef0de

See more details on using hashes here.

File details

Details for the file countsy-1.0.8-py3-none-any.whl.

File metadata

  • Download URL: countsy-1.0.8-py3-none-any.whl
  • Upload date:
  • Size: 5.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.0

File hashes

Hashes for countsy-1.0.8-py3-none-any.whl
Algorithm Hash digest
SHA256 02dd2a18445b85c5f4277333e46677289446f72e08c171b2af753b85f76b173e
MD5 bad637677b6983d93721800e8ee81bbb
BLAKE2b-256 663d9cc6e5386105701d4b34534cc56883aee90f95bbfb41dc0fe302221b0e04

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