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

Rebuild causes build errors in Visual Studio 2020 Preview 4 and Visual Studio 2019 #11215

Closed
JohnBergman opened this issue Sep 28, 2021 · 2 comments
Labels

Comments

@JohnBergman
Copy link

Which exact Umbraco version are you using? For example: 8.13.1 - don't just write v8

9.0.0

Bug summary

Brand new project created using the visual studio 2020 File-New method.

close, reopen visual studio, then do a rebuild all with multiple projects of multiple types (in my case I have a database project, a couple of class libraries that are .net 5, and the umbraco project.

Right-clicking on the solution and choosing rebuild leaves a bunch of build errors, as seen in the imag
Rebuild Errors
es

If I right click on the project itself and select build or rebuild it is fine.

Specifics

No response

Steps to reproduce

See the bug summary for a way to see the repo steps.

Expected result / actual result

Regardless of how I choose the build/rebuild, the results should be consistent.

@OzoneNZ
Copy link
Contributor

OzoneNZ commented Sep 28, 2021

Can confirm this happens in Visual Studio 2019 as well as 2022 Preview 4, could you update the issue title @JohnBergman?

Issue seems to be the BeforeTargets value specified on the CopyUmbracoAssets target here, which is leading to the target being skipped when running a Rebuild rather than just a Build

https://github.com/umbraco/Umbraco-CMS/blob/release-9.0.0/build/NuSpecs/build/Umbraco.Cms.StaticAssets.targets

BeforeTargets="Rebuild;Build" rather than just BeforeTargets="Build" may fix this

Replicated on a fresh 9.0.0 project

PZPpEVXscy

@JohnBergman JohnBergman changed the title Rebuild causes build errors in Visual Studio 2020 Preview 4 Rebuild causes build errors in Visual Studio 2020 Preview 4 and Visual Studio 2019 Sep 29, 2021
@p-m-j
Copy link
Contributor

p-m-j commented Sep 30, 2021

Closed by #11216

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

No branches or pull requests

4 participants