I am using a forfiles command line like this (Windows 7 x64):
forfiles /P "C:\root" /M "*.txt" /C "cmd /C echo @relpath"
How can I escape the replacement of @relpath (relative path to currently iterated item) to get @relpath output literally? (...or any other @ variable?)
So far I tried the following things, without success:
\: the@seems to be handled before\so\@relpathdoes not work, rather the expanded output is just preceded with\;^: stating^@does not show any effect except that the^disappears; writing^^@does not help eigher, one^remains in the expanded output then;0xHH: surprisingly (to me), theforfiles-specific replacement of hexacecimal numbers0x40does not work either, it seems that this is done prior to variable parsing;@@: doubling the@keeps the first@literally, that is it;