I am trying to execute a window batch command in Jenkins, and it is not working. I have reviewed Run batch command in jenkins, but I couldn't fix from that post.
I ran the following command to copy a file to a new location and give it a new name:
copy /B "%my_home%\base\dist\proj*.war" "%my_home%\base\dist\wars\proj.war"
In my case, the source directory has a single file called proj123.war. The file is successfully copied the the target directory, but the name remains proj123.war rather than renaming to proj.war.
Any idea what I might be doing wrong? Thanks for any help!