4

I'm trying to make a simple bash file to generate a specific structure (for php files) that is required on my job.

SET FILE_LIST=(Ex1.php Ex2.php)

FOR %%i IN %FILE_LIST% do echo ?php > %%i
FOR %%i IN %FILE_LIST% do echo. >> %%i
FOR %%i IN %FILE_LIST% do echo /* >> %%i
FOR %%i IN %FILE_LIST% do echo !IniHeaderDoc >> %%i
....

The thing is that the first line of FOR loop should write the open php tag

<?php

But I can't find the way to scape the "<" symbol. The same thing happens with closure of php tag...

Doing some research I read about that "<" and ">" symbols are not escapable on .bat files..

So, is there a way to escape these symbols?

Camilo Salas
  • 143
  • 2
  • 10

0 Answers0