Search found 1 match
- 21 Dec 2011 12:05
- Forum: DOS Batch Forum
- Topic: Piped input and output to a batch file
- Replies: 18
- Views: 26403
Piped input and output to a batch file
Folks, I wrote a simple batch file to take a file and add a prefix and a suffix to every line in the file. Example: "append pre suf file.ext" :: append.bat @echo off SETLOCAL set prefix=%~1 set suffix=%~2 set f=%~3 (for /f "tokens=1,* delims=:" %%a in (%f%) do ( (echo.%prefix% &q...