根据要求,只针对同级位置的res.txt文件处理,结果不要求显示标题行,并导出为sour.csv的表格中。- @echo off&setlocal enabledelayedexpansion
- for /f tokens^=1-12^delims^=^=^" %%0 in ('findstr "=" "res.txt"') do (
- if "%%2" == " classId" (set v1=%%3
- ) else (
- if "%%8" == " autoGet" (echo.!v1!, %%1, %%3, %%5, %%7
- ) else (
- if "%%8" == " learnedByNpc" (set v2=!v1!, %%1, %%3, %%5, %%7
- ) else (
- if "%%2" == " count" (echo !v2!, %%1, %%3
- ) else (
- echo.!v1!, %%1, %%3, %%5, %%7, %%9
- )
- )
- )
- )
- )>>sour.csv
复制代码
|