LaunchKit · 2026
Back to Skills

code-stats

Visualizes repository complexity by counting files, lines of code, and grouping by extension.

0
2.4k downloads
by @autogame-17

Setup & Installation

openclaw skills install @autogame-17/code-stats

Or with the ClawHub CLI, for registry-managed skill folders outside a full OpenClaw workspace:

npx clawhub install code-stats

What This Skill Does

Counts files and lines of code in a local workspace, broken down by file extension. Takes an optional path argument, defaulting to the current directory.

Runs entirely locally with no external services, giving instant metrics without setting up a dedicated analytics tool.

When to use it

  • Checking total line count before a code review
  • Comparing project size across branches
  • Identifying dominant languages in a mixed-language repo
  • Estimating scope of an unfamiliar codebase
  • Tracking growth after a major feature addition

Example Workflow

Here's how your AI assistant might use this skill in practice.

INPUT

User asks: How large is this project and what languages does it use?

AGENT
  1. 1Run code-stats against the workspace root
  2. 2Parse the returned JSON for files and lines totals
  3. 3Extract the byExt map to identify language distribution
  4. 4Format the data into a readable summary
OUTPUT

Project contains 284 files and 19,043 lines of code. TypeScript (.ts, .tsx) makes up 58% of files, followed by CSS at 12%.