analyzing-code

A code-analysis tool guide that uses Tokei to count and summarize source code by programming language and file. Tokei is a command-line utility for measuring code statistics.

In plain words
What is it for?
Use it to understand a project’s language mix, measure the impact of changes, inspect file-level statistics, or produce coding metrics for CI/CD.
Why use it?
It provides consistent code measurements without manually inspecting files or running ad hoc shell commands.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/sebastiendegodez/copilot-instructions/analyzing-code
Any agent
npx skills add SebastienDegodez/copilot-instructions --skill analyzing-code
Clone the repo
git clone --depth 1 https://github.com/SebastienDegodez/copilot-instructions

Made for: Claude Code, Codex.

Per session 26 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 903 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00026 $0.00903
Opus 5 $0.00013 $0.00451
Sonnet 5 $0.00005 $0.00181
Haiku 4.5 $0.00003 $0.00090

Measured 3d ago against content hash af7a374a5670, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

analyzing-code scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/minimal-context-tools/skills/analyzing-code/SKILL.md · 95 lines

How it starts

The opening of the file, as written. The whole thing — 95 lines — stays where its author put it; the contents beside it link to each section on GitHub.

tokei: Code Statistics Analysis

Always invoke analyzing-code skill for code statistics - do not execute bash commands directly.

Use tokei for fast, accurate code statistics across multiple languages and projects.

Default Strategy

Invoke analyzing-code skill for analyzing code statistics by language. Use when understanding project composition, measuring change impact before refactoring, or generating CI/CD metrics.

Common workflow: analyzing-code skill → other skills (finding-files, querying-json, querying-yaml) for filtering or analyzing-code skill after refactoring to measure impact.

Key Options

Basic Output Control

  • -f/--files show individual file statistics
  • -l/--languages list supported languages and extensions
  • -v/--verbose show unknown file extensions (1-3)
  • -V/--version show version information
  • --hidden include hidden files
  • -c/--columns N set strict column width

Filtering & Exclusion

  • -t/--type TYPES filter by language types (comma-separated)
  • -e/--exclude PATTERNS exclude files/dirs (gitignore syntax)
  • --no-ignore don't respect ignore files
    • --no-ignore-dot don't respect .ignore/.tokeignore
    • --no-ignore-vcs don't respect VCS ignore files
    • --no-ignore-parent don't respect parent ignore files

Output Formats

  • -o/--output FORMAT output format (json|yaml|cbor)
    • Requires compilation with features: cargo install tokei --features all
  • -i/--input FILE read from previous tokei run or stdin

Sorting Options

  • -s/--sort COLUMN sort by column
    • Possible values: files|lines|blanks|code|comments

Detailed Reference

For comprehensive usage patterns, output formats, language filtering, and integration examples, load tokei guide when needing:

  • Advanced language filtering and exclusion
  • JSON/YAML output processing
  • CI/CD integration patterns
  • Docker usage examples
  • Performance tuning for large codebases

The guide includes:

  • Basic usage and output control options
  • Language filtering and exclusion patterns
  • Output format configuration (JSON, YAML, CBOR)
  • Performance tips for large codebases
  • Docker usage and CI/CD integration
  • Configuration files and environment variables

Read the full file on GitHub · 95 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 95 lines · 26 tokens per session scan A af7a374a5670

Subscribe to this mod's changes

analyzing-code is a skill published in the GitHub repository SebastienDegodez/copilot-instructions (192 stars, last pushed 1mo ago), licensed Apache-2.0. It adds 26 tokens to every session and 903 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.