Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Directory files not copied to output on dotnet build in VSTS #2157

Closed
rschiefer opened this issue Jul 29, 2016 · 1 comment
Closed

Directory files not copied to output on dotnet build in VSTS #2157

rschiefer opened this issue Jul 29, 2016 · 1 comment

Comments

@rschiefer
Copy link

I added a "Deployment" directory to my ASP.NET Core site with a PowerShell file in it. I marked this directory to copyToOutput in the project.json.

  "buildOptions": {
    "emitEntryPoint": true,
    "preserveCompilationContext": true,
    "copyToOutput": {
      "include": [ "Deploy" ]
    }

This appears to work fine locally. The ps1 file is always updated in the bin folder.

In VSTS however it only appears to be copied one time and then not updated on subsequent builds. I am using a VS Build task in my build def. I was only able to get it to update if I added a task to delete the bin folder first.

With further testing I think I resolved this issue by tweaking my include to point to the files in the folder instead of the folder itself.

  "buildOptions": {
    "emitEntryPoint": true,
    "preserveCompilationContext": true,
    "copyToOutput": {
      "include": [ "Deploy/**" ]
    }

I have not done extensive testing here just wanted to see if others have seen the same behavior. This was super confusing and I wasted a couple days on it.

@bryanmacfarlane
Copy link
Contributor

This seems like feedback for dotnet build tool. You're not having an issue with any of the tasks in this repro. We will however create dotnet build tasks and/or templates as the dust settles and the dotnet tools get closer to release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants