A AhaTools

Code Lines

Count non-empty code without installing anything.

Run it at a Git repository root. It opens a small terminal menu for Chinese or English results, scale notes, scope, and extension breakdown.

macOS / Linux / Git Bash

bash <(curl -fsSL tools.ahaknow.com/scripts/code-lines.sh)

Windows PowerShell

irm https://tools.ahaknow.com/scripts/code-lines.ps1 | iex
macOS / Linux / Git Bash
curl -fsSL https://tools.ahaknow.com/scripts/code-lines.sh -o /tmp/code-lines.sh
less /tmp/code-lines.sh
bash /tmp/code-lines.sh
Windows PowerShell
Invoke-WebRequest https://tools.ahaknow.com/scripts/code-lines.ps1 -OutFile $env:TEMP\code-lines.ps1
notepad $env:TEMP\code-lines.ps1
pwsh -NoProfile -ExecutionPolicy Bypass -File $env:TEMP\code-lines.ps1