How to create an infinite loop in Windows batch file?
Unlimited loop in one-line command for use in cmd
windows:
FOR /L %N IN () DO @echo Oops
How about using good(?) old goto
?
:loop
echo Ooops
goto loop
See also this for a more useful example.