Reputation: 33
I am trying to copy files from one folder to another in windows with jenkins.
Build script is as follows:
xcopy /s /Y "$WORKSPACE\\artifacts\\*.*" "$WORKSPACE\\publish-output"
Console Output: Invalid number of parameters
Upvotes: 1
Views: 2983
Reputation: 340
What do you mean by "windows" ? I assume the jenkins server is on Windows OS or the slave node is a windows os. At the same time you have tagged "bash" Do you mean "batch" ? Referring to $Workspace is not windows style either, you should be using %workspace% An example:
Try the command like:
xcopy /s /Y %WORKSPACE%\dir1*.* %WORKSPACE%\dir2.
This should work.
Upvotes: 2