Copy one file in target directory on deploy from v

2020-01-25 06:07发布

I'm using VSTS as a build server, and while building I want to copy the bin folder contents to the root of the target, and also custom files from another folder to this target. MSDN suggests I use a minimatch pattern, but it's copying files with the subdirectory structure. I'm not interested in restoring the structure.

For example, I am getting this folder structure:

Project
    MyProjectFiles
    bin
        x86 (it's build configuration)
            Project.exe
    Other project files
    Project.sln
SomeScrips
    script1.ps1

But I want to receive this folder structure:

Project.exe
SomeScripts
    script.ps1

Which minimatch pattern can I use for my requirements?

7条回答
兄弟一词,经得起流年.
2楼-- · 2020-01-25 07:09

Make artifacts of each file you want to copy. Then create a 'copy file' task of each file of these artifacts. Then it doesn't copy the source tree structure.

查看更多
登录 后发表回答