I get unexpected results with this batch file:
TC doesn't run the grep command correctly, and then it also executes test.txt after each grep command, opening the file in Notepad. If I restructure it to look like this, everything works correctly:
CMD behaves correctly with both layouts. It seems TC has an issue when there are line breaks in the set.
I confirmed this on both 15.01.52 and 15.01.54.
Code:
@echo off
for %%a in (
123
234
345
456
) do (
grep %%a test.txt
)
TC doesn't run the grep command correctly, and then it also executes test.txt after each grep command, opening the file in Notepad. If I restructure it to look like this, everything works correctly:
Code:
@echo off
for %%a in (123 234 345 456) do (
grep %%a test.txt
)
CMD behaves correctly with both layouts. It seems TC has an issue when there are line breaks in the set.
I confirmed this on both 15.01.52 and 15.01.54.