# cpp-auto-print **Repository Path**: externzhang/cpp-auto-print ## Basic Information - **Project Name**: cpp-auto-print - **Description**: 摸鱼必备 1 打开指定文件并按可控速度打印内容,比如build.log 2 收集.c/.h/.cpp文件并按指定速度打印代码内容 - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-11-26 - **Last Updated**: 2025-11-26 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README 1. **print-tree-cpp.py** 收集.c/.h/.cpp文件并按指定速度打印代码内容 usage: print-tree-cpp.py [-h] [--dir DIR] [--txt TXT] [--line-speed LINE_SPEED] [--file-interval FILE_INTERVAL] options: -h, --help show this help message and exit --dir, -d DIR 目标遍历目录(默认当前目录) --txt, -t TXT 保存文件路径的txt文件名(默认treelist.txt) --line-speed, -ls LINE_SPEED 代码行打印延迟秒数(默认0,立即打印) --file-interval, -fi FILE_INTERVAL 文件间的打印间隔秒数(默认1秒) **example** ``` python.exe .\print-file.py -f .\build.log ``` 1. **print-file.py** 打开指定文件并按可控速度打印内容 usage: print-file.py [-h] --file FILE [--speed SPEED] options: -h, --help show this help message and exit --file, -f FILE 要打印的文件路径(绝对/相对路径,必填) --speed, -s SPEED 逐行打印的延迟秒数(默认0.1,0为立即打印) **example** ``` python.exe .\print-tree-cpp.py -ls 0.1 ``` 环境准备:确保安装 Python 3.6+(执行`python --version`验证)。