Skills DirectorySkills Directory
SkillsLearnSecurityCategoriesDocsBlogPro
Sign InSubmit Skill
Skills Directory

Security-tested agent skills for Claude, coding agents, and AI workflows.

Directory

  • Browse Skills
  • All Skills A–Z
  • Claude Skills
  • Claude Code Skills
  • Agent Skills
  • Categories
  • Authors
  • Submit a Skill

Learn

  • Learn Hub
  • Install Claude Skills
  • Write SKILL.md
  • Skills vs MCP
  • Directories Compared

Security

  • Security
  • Methodology
  • Secure Claude Skills
  • Security Badges
  • Chrome Extension
  • Skill Manager

Company

  • About
  • Community
  • Blog
  • API Docs
  • Advertise

2026 Skills Directory. All rights reserved.

ProTermsPrivacyRefunds
Back to skills

Think In Code

ASecurity

Use ONE Bash script instead of N sequential Read calls when analyzing multiple files, auditing codebase, finding all matches, scanning dependencies, counting lines, or listing files matching a pattern. Replaces wasteful multi-Read loops with compact shell pipelines.

29 stars
0 votes
0 copies
1 views
Added 5/28/2026
ai-agentsphpshellbashnodegit

Security Analysis

A100/100

Scanned 5/28/2026

$npx -y skills add fusengine/agents --skill think-in-code --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Think In Code?

Add the live security badge to your README — it updates automatically with every re-scan.

Security grade badge for Think In Code
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/fusengine-think-in-code/badge)](https://www.skillsdirectory.com/skills/fusengine-think-in-code)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
Files
SKILL.md
---
name: think-in-code
description: Use ONE Bash script instead of N sequential Read calls when analyzing multiple files, auditing codebase, finding all matches, scanning dependencies, counting lines, or listing files matching a pattern. Replaces wasteful multi-Read loops with compact shell pipelines.
argument-hint: "[pattern] [scope]"
keywords:
  - analyse multiple fichiers
  - audit codebase
  - find all
  - scan dependencies
  - count lines
  - list files matching
  - bulk read
user-invocable: false
---

# Think-in-Code Skill

## Principle

**1 Bash script = N Read calls avoided.**

When you'd read 10 files sequentially to extract a summary, you waste tokens loading full contents into context. Instead: 1 shell pipeline returns the compact aggregated result.

Heuristic: if your task is "for each file in set, compute/extract X, then aggregate" → write the script. Reserve Read for *targeted inspection* of a specific file you already know matters.

## 5 Runnable Patterns

### 1. File size audit (> 100 lines violations)

```bash
find . -type f \( -name "*.ts" -o -name "*.tsx" -o -name "*.py" -o -name "*.php" \) \
  -not -path "*/node_modules/*" -not -path "*/vendor/*" \
  | xargs wc -l 2>/dev/null \
  | awk '$1 > 100 && $2 != "total" {print $1, $2}' \
  | sort -rn | head -20
```

### 2. Multi-grep symbols (compact JSON)

```bash
rg --json -g '*.ts' -g '*.tsx' 'export (function|class|const) (\w+)' src/ \
  | jq -r 'select(.type=="match") | "\(.data.path.text):\(.data.line_number) \(.data.lines.text)"' \
  | head -50
```

### 3. Dependencies with versions

```bash
# Node
jq -r '.dependencies, .devDependencies | to_entries[] | "\(.key)@\(.value)"' package.json 2>/dev/null

# PHP
jq -r '.require, ."require-dev" | to_entries[] | "\(.key)@\(.value)"' composer.json 2>/dev/null
```

### 4. Error log scan

```bash
grep -rEn 'ERROR|FATAL|Exception|panic:|stack trace' \
  --include="*.log" logs/ 2>/dev/null \
  | tail -30
```

### 5. Lines of code by extension

```bash
find . -type f \( -name "*.ts" -o -name "*.tsx" -o -name "*.js" -o -name "*.py" -o -name "*.php" \) \
  -not -path "*/node_modules/*" -not -path "*/vendor/*" -not -path "*/.git/*" \
  -exec wc -l {} + \
  | awk '{ext=$2; sub(/.*\./,"",ext); sum[ext]+=$1} END {for (e in sum) print sum[e], e}' \
  | sort -rn
```

## Anti-Pattern

**Do NOT** Read 10 files sequentially to count their lines, list their exports, or check their size. That is ~6KB context per file = ~60KB wasted for a result that fits in 1KB.

```
WRONG: Read(f1.ts) → Read(f2.ts) → ... → Read(f10.ts) → manual tally
RIGHT: Bash(find ... | xargs wc -l | awk ...) → 1 compact table
```

## Before / After

**Task:** "Find files > 100 lines in `src/`."

- Before: 10 × Read full file → ~60KB tokens consumed, then mental wc.
- After: 1 × `find src -name '*.ts' | xargs wc -l | awk '$1>100'` → ~1KB result.

**~60× reduction. Use the script.**

Attribution

fusenginefusengine
View sourceSee grades on GitHubMore from fusengine →
SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments (0)

No comments yet. Be the first to comment!

SSkills DirectorySkills Directory

Ship a skill? Prove it's safe.

Free 120-pattern security scan, letter grade, and an embeddable README badge.

Submit a skill

Related Skills

Caveman

Terse caveman voice: answer first, fluff gone, every technical fact kept. Use for /caveman, "caveman mode", "talk like caveman", "be brief", "less tokens". Stays on until "stop caveman" or "normal mode".

1100021 votes

Hyperplan

Adversarial multi-agent planning skill. Self-orchestrates 5 hostile category members (unspecified-low, unspecified-high, deep, ultrabrain, artistry) via team-mode for ruthless cross-critique debate, distills only the defensible insights, then MANDATORILY hands the distilled insight bundle to the `plan` agent for executable plan formalization. Use when planning needs maximum rigor and surfacing of weak assumptions, blind spots, and over-engineering. Triggers: 'hyperplan', 'hpp', '/hyperplan', ...

698461 votes

Writing Skills

Create and manage Claude Code skills in HASH repository following Anthropic best practices. Use when creating new skills, modifying skill-rules.json, understanding trigger patterns, working with hooks, debugging skill activation, or implementing progressive disclosure. Covers skill structure, YAML frontmatter, trigger types (keywords, intent patterns), UserPromptSubmit hook, and the 500-line rule. Includes validation and debugging with SKILL_DEBUG. Examples include rust-error-stack, cargo-dep...

3931 votes

Mcp Code Execution

Routes multi-tool workflows through MCP servers for large datasets and pipelines. Use when Bash tool overhead is limiting throughput on data-heavy tasks.

3421 votes

catchup

Recovers the conversation and failed tool calls of a previous Codex, Amp, Claude Code, Antigravity, Cline, Copilot CLI, Cursor, DeepSeek Harness, Grok Build, Kimi, OpenCode, Pi Agent, or ZCode session. Use when the user says "catch up", "what did the last session do", "get me up to speed", "I switched agents", asks to recover/summarize a previous session before continuing, or asks to diagnose or report a catchup failure. Do NOT use for the current conversation, git history, or any non-agent log.

741 votes
View all in ai-agents →