* Format files as a flat list
(files: { path: string; language: string; nodeCount: number }[], includeMetadata: boolean)
| 4253 | * Format files as a flat list |
| 4254 | */ |
| 4255 | private formatFilesFlat(files: { path: string; language: string; nodeCount: number }[], includeMetadata: boolean): string { |
| 4256 | const lines: string[] = [`**Files (${files.length})**`, '']; |
| 4257 | |
| 4258 | for (const file of files.sort((a, b) => a.path.localeCompare(b.path))) { |
| 4259 | if (includeMetadata) { |
| 4260 | lines.push(`- ${file.path} (${file.language}, ${file.nodeCount} symbols)`); |
| 4261 | } else { |
| 4262 | lines.push(`- ${file.path}`); |
| 4263 | } |
| 4264 | } |
| 4265 | |
| 4266 | return lines.join('\n'); |
| 4267 | } |
| 4268 | |
| 4269 | /** |
| 4270 | * Format files grouped by language |