powershell - Windows Shell. Restoring Orig Files -
after quick google search found link: mercurial: simple way revert .orig files?, following line of code in comment:
for /f %i in ('dir /s /b *.orig') @copy %i %~dpni
in powershell, tried running it, got following error: missing opening ( after kyeword for
.
is powershell not correct way run code or syntax incorrect?
i trying revert orig files original version (get rid of .orig extension). using windows bash not easy option.
the comment snippet came suggests environment can run line in "windows command prompt command extensions."
you can create environment so: cmd /e:on
. didn't seem using powershell intention, type cmd /e:on
powershell console , environment.
ps c:\> cmd /e:on microsoft windows [version 6.1.7601] copyright (c) 2009 microsoft corporation. rights reserved. c:\> command prompt input valid here
you received error because syntax incorrect powershell -- for
statements expect parameters in parenthesis. should work once you're in appropriate shell, though.
Comments
Post a Comment