AGENT SKILL
treex
Use this skill when the user wants to visualize directory structure, list files in tree format, generate project overviews, or export directory listings in JSON, CSV, Markdown, or Mermaid formats.
- License 许可
- MIT
- 最近更新
- 2026-11-02
- Stars
- ★ 57
- Forks
- 5
01 前言 Front Matter
- name
- treex
- description
- Use this skill when the user wants to visualize directory structure, list files in tree format, generate project overviews, or export directory listings in JSON, CSV, Markdown, or Mermaid formats.
03 SKILL.md 正文
treex Plugin
Directory structure visualization CLI with multiple output formats (tree, indent, markdown, mermaid, JSON, CSV) and powerful filters for max-depth, exclusions, gitignore, and metadata.
Commands
Directory Visualization
treex dir tree— Generate directory structure visualization
Utility
treex self version— Print treex versiontreex _ _— Passthrough to treex CLI
Usage Examples
- "Show the directory tree for the current folder"
- "Export the project structure as a Markdown file"
- "Generate a Mermaid diagram of the directory structure"
- "List all files as JSON with sizes and owners"
- "Show only directories, excluding node_modules and .git"
- "Create a tree visualization respecting .gitignore"
Installation
go install github.com/shiquda/treex@latest
Examples
# Basic tree for current directory
treex dir tree
# Tree with max depth of 3
treex dir tree -m 3
# JSON output
treex dir tree -f json
# CSV output for spreadsheet
treex dir tree -f csv
# Markdown output
treex dir tree -f md
# Mermaid diagram output
treex dir tree -f mermaid
# Save tree to a file
treex dir tree -o project-structure.md -f md
# Show file sizes and modification times
treex dir tree -s -M
# Show owners
treex dir tree -O
# Hide hidden files
treex dir tree -H
# Only directories
treex dir tree -D
# Respect .gitignore
treex dir tree -I
# Exclude specific directories or extensions
treex dir tree -e node_modules/,dist/,build/
# Exclude by extension
treex dir tree -e .log,.tmp
# Show icons
treex dir tree -C
# Combine multiple options
treex dir tree -d . -m 4 -f json -s -M -I -H
Key Features
- Multiple output formats: tree (default), indent, markdown, mermaid, json, csv
- Max depth control:
-mor-Lto limit directory depth - Size display:
-sshows human-readable file sizes - Owner display:
-Oshows file owners - Modification time:
-Mshows file modification times - Hidden files:
-Hhides hidden files and directories - Directories only:
-Dshows only directories - Gitignore support:
-Iautomatically applies.gitignorerules - Exclusion rules:
-eto exclude specific directories (dir/) or extensions (.ext) - File output:
-osaves output to a file - Icons:
-Cshows emoji icons for files - Improved Windows pipe support with UTF-8 encoding
Output Formats
- tree: Classic tree format with branches (default)
- indent: Indented list format
- md: Markdown format with headers and lists
- mermaid: Mermaid diagram format for documentation
- json: Structured JSON with file/directory metadata
- csv: CSV format for spreadsheet applications
Notes
- Run without arguments to generate a tree for the current directory
-Lis an alias for-mfor better compatibility with standard tree commands- Exclusion rules support both directory names ending with
/and file extensions - On Windows, improved pipe support with UTF-8 encoding is available
- Large directory trees may take a moment to process; use
-mto limit depth
04 同仓库更多 Skills
sc-machin-mcp
暂无简介
★ 57
supercli.quickstart
SuperCLI capability router — discover and execute CLI commands through namespace.resource.action interface
★ 57
zzdoc
Use this skill to compile scdoc manpages with a fast Zig-based compiler.
★ 57
zx
Use this skill when the user wants to a tool for writing better scripts using node.js.
★ 57
zvm
Use this skill when the user wants to manage multiple Zig compiler versions.
★ 57
quickstart
暂无简介
★ 57