---
name: "loc bot command — top files by line count"
---

# Story 410: loc bot command — top files by line count

## User Story

As a developer, I want to send `loc` to the bot and see the top files by line count, so I can spot files that are getting too large before they become a problem for agents.

## Acceptance Criteria

- [ ] loc command is registered in chat/commands/mod.rs and appears in help output
- [ ] `loc` returns the top 10 source files by line count (excluding generated files, node_modules, target/, .huskies/worktrees/)
- [ ] `loc 5` returns the top 5 files
- [ ] `loc 20` returns the top 20 files
- [ ] Output includes file path, line count, and rank
- [ ] Command works from all transports (Matrix, WhatsApp, Slack)

## Out of Scope

- TBD
