Commit a9938ef
committed
✨ [feat] Add ANSI file analysis and display utilities for terminal size optimization
Introduces two new PowerShell utilities to enhance ANSI art file management and discovery:
**Analyze-UnusedAnsiFiles.ps1** 📊
- Scans unused ANSI files to identify those fitting standard terminal dimensions (≤120 columns, ≤50 lines)
- Implements CP437 encoding support for proper DOS/OEM character rendering
- Strips SAUCE metadata (a standard container format for ANSI art) to extract embedded dimension hints
- Calculates actual terminal dimensions by:
- Removing ANSI escape sequences from line content
- Parsing cursor positioning commands to infer layout
- Detecting single-line wrapped content and estimating height
- Provides flexible output options: CSV export, file copying, or automated PowerShell script conversion
- Generates detailed reports with size distribution analysis and error handling
- Enables batch conversion of suitable files to PowerShell ColorScript format
**Show-AscFile.ps1** 🎨
- Displays ASCII/ANSI art files with proper encoding (CP437)
- Handles both raw and gzip-compressed files transparently
- Clears screen before rendering for clean presentation
Both utilities support the workflow of curating and converting legacy ANSI art assets into modern PowerShell color scripts, automating the discovery of viable candidates based on terminal compatibility constraints.
Signed-off-by: Nick2bad4u <20943337+Nick2bad4u@users.noreply.github.com>1 parent 7a9eb52 commit a9938ef
2 files changed
Lines changed: 520 additions & 0 deletions
0 commit comments