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

Treat warnings as errors for initial projects #15019

Merged
merged 21 commits into from
Aug 27, 2024
Merged
Show file tree
Hide file tree
Changes from 15 commits
Commits
Show all changes
21 commits
Select commit Hold shift + click to select a range
d59b5fb
Treat warnings as errors for Umbraco.Cms, Umbraco.Cms.Api.Common and …
Oct 22, 2023
5400f83
Treat warnings as errors for Umbraco.Cms.Imaging.ImageSharp and Umbra…
Oct 22, 2023
731acff
Treat warnings as errors for Umbraco.Cms.Persistence.EFCore.Sqlite, U…
Oct 22, 2023
171bd1f
Treat warnings as errors for Umbraco.Cms.Targets
Oct 22, 2023
b4503bc
Treat warnings as errors for templates/Umbraco.Templates and Umbraco.…
Oct 22, 2023
01f238b
Merge branch 'contrib' into hotfix/15015-warnings-aserrors
Dec 1, 2023
bbc76c3
More projects with warnings as errors.
Dec 1, 2023
0fc018f
Merge branch 'contrib' into hotfix/15015-warnings-aserrors
Dec 11, 2023
1013c3a
Merge branch 'contrib' into hotfix/15015-warnings-aserrors
Feb 26, 2024
6e495f5
Merge branch 'contrib' of https://github.com/umbraco/Umbraco-CMS into…
Mar 5, 2024
2267422
Merge branch 'contrib' into hotfix/15015-warnings-aserrors
emmagarland Aug 13, 2024
1aa4b34
Merge branch 'umbraco:contrib' into hotfix/15015-warnings-aserrors
emmagarland Aug 13, 2024
c7a42f6
Reverted warnings as errors due to some file changes since the update.
emmagarland Aug 13, 2024
a28830e
Remove unwanted tag
emmagarland Aug 13, 2024
19ce08a
Removed warnings as errors on TestData project
emmagarland Aug 13, 2024
3f48233
Merge branch 'umbraco:contrib' into hotfix/15015-warnings-aserrors
emmagarland Aug 23, 2024
00a0d25
Implement warnings as errors in props file, and exclude specific warn…
emmagarland Aug 24, 2024
3734c45
Reverted spaces
emmagarland Aug 24, 2024
5a390ad
Revert "Reverted spaces"
emmagarland Aug 24, 2024
9b2b951
Update sdk version to fully support Umbraco.code 2.2.0 dependency on …
Migaroez Aug 26, 2024
4c469b6
Ignore PathToLongErrors for now in static assets
Migaroez Aug 26, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/Umbraco.Cms.Api.Common/Umbraco.Cms.Api.Common.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
<Title>Umbraco CMS - API Common</Title>
<Description>Contains the bits and pieces that are shared between the Umbraco CMS APIs.</Description>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>

<ItemGroup>
<FrameworkReference Include="Microsoft.AspNetCore.App" />
Expand Down
6 changes: 6 additions & 0 deletions src/Umbraco.Cms.Api.Delivery/Umbraco.Cms.Api.Delivery.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
<Title>Umbraco CMS - Delivery API</Title>
<Description>Contains the presentation layer for the Umbraco CMS Delivery API.</Description>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>False</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>False</TreatWarningsAsErrors>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\Umbraco.Cms.Api.Common\Umbraco.Cms.Api.Common.csproj" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
<Title>Umbraco CMS - Imaging - ImageSharp</Title>
<Description>Adds imaging support using ImageSharp/ImageSharp.Web to Umbraco CMS.</Description>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
<Title>Umbraco CMS - Imaging - ImageSharp 2</Title>
<Description>Adds imaging support using ImageSharp/ImageSharp.Web version 2 to Umbraco CMS.</Description>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" VersionOverride="[2.1.9, 3)" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
<Title>Umbraco CMS - Persistence - Entity Framework Core - SQL Server migrations</Title>
<Description>Adds support for Entity Framework Core SQL Server migrations to Umbraco CMS.</Description>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>

<ItemGroup>
<!-- Take top-level depedendency on Azure.Identity, because Microsoft.EntityFrameworkCore.SqlServer depends on a vulnerable version -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@
<Title>Umbraco CMS - Persistence - Entity Framework Core - SQLite migrations</Title>
<Description>Adds support for Entity Framework Core SQLite migrations to Umbraco CMS.</Description>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" />
Expand Down
10 changes: 9 additions & 1 deletion src/Umbraco.Cms.StaticAssets/Umbraco.Cms.StaticAssets.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,14 @@
<LoginPath>$(BasePath)\login</LoginPath>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>

<Target Name="BuildStaticAssetsPreconditions" BeforeTargets="Build">
<Message Text="Skip BuildBellissima target because UmbracoBuild is '$(UmbracoBuild)' (this is not Visual Studio)" Importance="high" Condition="'$(UmbracoBuild)' != ''" />
<Message Text="Skip BuildBellissima target because '$(BellissimaPath)' already exists" Importance="high" Condition="Exists('$(BellissimaPath)')" />
Expand Down Expand Up @@ -66,4 +74,4 @@
</ItemGroup>
<RemoveDir Directories="@(LoginDirectories)" />
</Target>
</Project>
</Project>
6 changes: 6 additions & 0 deletions src/Umbraco.Cms.Targets/Umbraco.Cms.Targets.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,12 @@
<_UmbracoCmsPackageSchemaReference>umbraco-package-schema.json</_UmbracoCmsPackageSchemaReference>
<NoWarn>NU5100;NU5128</NoWarn>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Umbraco.JsonSchema.Extensions" PrivateAssets="all" GeneratePathProperty="true" />
<None Include="$(PkgUmbraco_JsonSchema_Extensions)\tasks\netstandard2.0\**" Pack="true" PackagePath="tasks\netstandard2.0" Visible="false" />
Expand Down
6 changes: 6 additions & 0 deletions src/Umbraco.Cms/Umbraco.Cms.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@
<IncludeBuildOutput>false</IncludeBuildOutput>
<IncludeSymbols>false</IncludeSymbols>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\Umbraco.Cms.Targets\Umbraco.Cms.Targets.csproj" />
Expand Down
7 changes: 7 additions & 0 deletions templates/Umbraco.Templates.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,13 @@
<ContentTargetFolders>.</ContentTargetFolders>
<NoWarn>NU5128</NoWarn>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>True</TreatWarningsAsErrors>
</PropertyGroup>

<ItemGroup>
<Content Include="..\src\Umbraco.Web.UI\Program.cs">
<Link>UmbracoProject\Program.cs</Link>
Expand Down
6 changes: 6 additions & 0 deletions tests/Umbraco.TestData/Umbraco.TestData.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,10 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>False</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>False</TreatWarningsAsErrors>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Bogus" />
</ItemGroup>
Expand Down
6 changes: 6 additions & 0 deletions tools/Umbraco.JsonSchema/Umbraco.JsonSchema.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
<IsPackable>false</IsPackable>
<EnablePackageValidation>false</EnablePackageValidation>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<TreatWarningsAsErrors>False</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<TreatWarningsAsErrors>False</TreatWarningsAsErrors>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="CommandLineParser" VersionOverride="2.9.1" />
Expand Down
Loading