Open Source
v0.1.2

count

A blazing-fast Rust command-line tool for counting lines, words, and characters. Parallel processing, smart pattern matching, and intelligent directory traversal.

Terminal
$ count -R src/
Processed 1,247 files
Total lines: 89,432
Time: 0.034s

$ count -p "fn\s+\w+" src/ --match
Found 847 function definitions
In 156 files

Powerful Features

Built for speed with modern Rust performance

Parallel Processing

Lightning-fast multi-threaded counting using Rayon. Processes multiple files simultaneously for maximum performance.

Smart Pattern Matching

Count occurrences of specific patterns with regex support. Find function definitions, TODO comments, and more.

Intelligent File Handling

Automatic binary file detection and exclusion. Handles various text encodings and line endings gracefully.

Hierarchical Statistics

Get detailed statistics for each directory and subdirectory. Perfect for understanding project structure.

Clean Output

Human-readable output with customizable formatting. JSON output option for integration with other tools.

Cross-Platform

Works seamlessly on Linux, macOS, and Windows. Single binary with no dependencies for easy deployment.

Usage Examples

Simple, powerful command-line interface

Basic Count

$ count main.rs

Recursive Directory

$ count -R src/

Pattern Matching

$ count -p "TODO" --match

JSON Output

$ count -R --json

Technical Details

Dependencies

  • clap - CLI argument parsing
  • rayon - Parallel processing
  • regex - Pattern matching
  • walkdir - Directory traversal

System Requirements

  • Rust 1.70.0 or higher
  • 64-bit operating system
  • Linux, macOS, or Windows

Ready to Count?

Get count and start analyzing your codebase instantly.

More Tools

Open-Source Projects

🔢

count

Fast line/word/character counter (this page)

📍

whereis

Cross-platform path finder

🔍

ninjagrep

Blazing-fast text search

🧹

build-cleanup

Smart build artifact cleanup