Skip to content
Back to skills

Folder Tree Generator

ASecurity

Generates an ASCII tree or JSON representation of a directory structure. Use when you need to visualize file hierarchies, document folder contents, or debug directory layouts.

  • 14 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 7, 2026
toolsbashnode

Security analysis

A100/100

Pro scans all 4 files and shows the line behind each finding

Scanned September 7, 2026

npx -y skills add modbender/skill-library-mcp --skill folder-tree-generator --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Folder Tree Generator?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Folder Tree Generator
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/modbender-folder-tree-generator/badge)](https://www.skillsdirectory.com/skills/modbender-folder-tree-generator)

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

Download with Pro
SKILL.md
---
name: folder-tree-generator
description: Generates an ASCII tree or JSON representation of a directory structure. Use when you need to visualize file hierarchies, document folder contents, or debug directory layouts.
---

# Folder Tree Generator

A utility skill to visualize directory structures in ASCII tree format or JSON.

## Usage

```bash
# Generate ASCII tree for current directory
node skills/folder-tree-generator/index.js

# Generate ASCII tree for specific directory
node skills/folder-tree-generator/index.js /path/to/dir

# Generate JSON output
node skills/folder-tree-generator/index.js --json

# Limit depth
node skills/folder-tree-generator/index.js --depth 2
```

## Options

- `--json`: Output as JSON.
- `--depth <n>`: Limit recursion depth.
- `[dir]`: Directory to scan (default: `.`).

## Examples

**ASCII Output:**
```
.
├── file1.txt
└── dir1
    ├── file2.txt
    └── file3.txt
```

**JSON Output:**
```json
{
  "name": ".",
  "type": "directory",
  "children": [
    { "name": "file1.txt", "type": "file" },
    { "name": "dir1", "type": "directory", "children": [...] }
  ]
}
```

Files in this skill

  • SKILL.md1.2 KB
  • index.js2.5 KB
  • package.json374 B
  • scripts/test.js1.2 KB

Attribution

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

Loading comments…