LaunchKit · 2026
Back to Skills

folder-tree-generator

Generates an ASCII tree or JSON representation of a directory structure.

0
606 downloads
by @wanng-ide

Setup & Installation

openclaw skills install @wanng-ide/folder-tree-generator

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

npx clawhub install folder-tree-generator

What This Skill Does

Generates a visual representation of a directory structure as either an ASCII tree or JSON. Accepts a target path, optional depth limit, and output format flag. Useful for documenting, sharing, or inspecting folder layouts.

Produces both human-readable ASCII and machine-parseable JSON from the same tool, removing the need to switch between separate utilities.

When to use it

  • Documenting project structure in a README
  • Debugging unexpected files in a build output directory
  • Sharing folder layout during a code review
  • Checking scaffold depth after generating a new project
  • Snapshotting directory contents before a refactor

Example Workflow

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

INPUT

User asks: Show the structure of /src limited to 2 levels deep

AGENT
  1. 1Run folder-tree-generator with /src and --depth 2
  2. 2Traverse the directory recursively up to 2 levels
  3. 3Format the result as an ASCII tree
  4. 4Return the formatted output
OUTPUT

ASCII tree of /src showing files and folders up to 2 levels deep