Skip to content

PR - Build with MSBuild 17.0, Visual Studio 2022. - #44

Open
MitaWinata wants to merge 1 commit into
Azure-Samples:masterfrom
MitaWinata:master
Open

PR - Build with MSBuild 17.0, Visual Studio 2022.#44
MitaWinata wants to merge 1 commit into
Azure-Samples:masterfrom
MitaWinata:master

Conversation

@MitaWinata

Copy link
Copy Markdown

Msbuild error NU1504, Duplicate 'PackageReference' items found for StyleCop.Analyzers.

Purpose

To have a successful build with MsBuild 17.0 , Visual Studio 2022

Does this introduce a breaking change?

[ ] Yes
[x] No

Pull Request Type

What kind of change does this Pull Request introduce?

[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Documentation content changes
[ ] Other... Please describe:

How to Test

git clone https://github.com/MitaWinata/nu1504_build_error
cd nu1504_build_error
git checkout master
msbuild /restore
msbuild IotTelemetrySimulator.sln

What to Check

Verify that the solution can be built.

Other Information

https://docs.microsoft.com/en-us/nuget/reference/errors-and-warnings/nu1504

Msbuild error NU1504, Duplicate 'PackageReference' items found for StyleCop.Analyzers.

https://docs.microsoft.com/en-us/nuget/reference/errors-and-warnings/nu1504
@gukoff

gukoff commented Mar 9, 2023

Copy link
Copy Markdown
Contributor

Would it work if you removed these lines altogether?

They seem redundant, as Stylecop.Analyzers are already included in all of these .csproj files via <Import Project="../../stylecop.props" /> (stylecop.props content)

@gukoff

gukoff commented Apr 14, 2023

Copy link
Copy Markdown
Contributor

ping @MitaWinata :)

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants