diff --git a/.gitignore b/.gitignore index cf0f7b4a3d..509117820d 100644 --- a/.gitignore +++ b/.gitignore @@ -47,10 +47,6 @@ NDependOut/ QueryResult.htm tools/docfx/ -# Ignore rule for clearing out Belle (avoid rebuilding all the time) -preserve.bellissima -preserve.login - # csharp-docs /build/csharp-docs/api/ /build/csharp-docs/_site/ diff --git a/Directory.Build.props b/Directory.Build.props index 03d2eae227..d2c4e87700 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -15,14 +15,20 @@ enable nullable true - - $(NoWarn);NU5104 - $(WarningsNotAsErrors);NU5104 enable true false + + + $(NoWarn),NU5104 + $(WarningsNotAsErrors),NU5104 + + true diff --git a/Directory.Packages.props b/Directory.Packages.props index af241ec408..b5e032d227 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -3,6 +3,7 @@ true + @@ -10,6 +11,7 @@ + @@ -35,11 +37,13 @@ + + @@ -77,25 +81,26 @@ + - + - + - + - + - + - + - + - \ No newline at end of file + diff --git a/src/Umbraco.Cms.Api.Common/Umbraco.Cms.Api.Common.csproj b/src/Umbraco.Cms.Api.Common/Umbraco.Cms.Api.Common.csproj index a1bd4e1694..2760181536 100644 --- a/src/Umbraco.Cms.Api.Common/Umbraco.Cms.Api.Common.csproj +++ b/src/Umbraco.Cms.Api.Common/Umbraco.Cms.Api.Common.csproj @@ -3,6 +3,7 @@ Umbraco CMS - API Common Contains the bits and pieces that are shared between the Umbraco CMS APIs. + @@ -13,14 +14,15 @@ + - - + + + - diff --git a/src/Umbraco.Cms.Api.Delivery/Umbraco.Cms.Api.Delivery.csproj b/src/Umbraco.Cms.Api.Delivery/Umbraco.Cms.Api.Delivery.csproj index 3e0075acfd..37816e2f6e 100644 --- a/src/Umbraco.Cms.Api.Delivery/Umbraco.Cms.Api.Delivery.csproj +++ b/src/Umbraco.Cms.Api.Delivery/Umbraco.Cms.Api.Delivery.csproj @@ -3,20 +3,21 @@ Umbraco CMS - Delivery API Contains the presentation layer for the Umbraco CMS Delivery API. + - - ASP0019 + + $(WarningsNotAsErrors),ASP0019,CS0618,CS0612 + - - - false - <_Parameter1>Umbraco.Tests.UnitTests diff --git a/src/Umbraco.Cms.Api.Management/Umbraco.Cms.Api.Management.csproj b/src/Umbraco.Cms.Api.Management/Umbraco.Cms.Api.Management.csproj index 2664abe675..34df686bd6 100644 --- a/src/Umbraco.Cms.Api.Management/Umbraco.Cms.Api.Management.csproj +++ b/src/Umbraco.Cms.Api.Management/Umbraco.Cms.Api.Management.csproj @@ -2,22 +2,27 @@ Umbraco CMS - Management API Contains the presentation layer for the Umbraco CMS Management API. - true - false - Umbraco.Cms.Api.Management - Umbraco.Cms.Api.Management + - - - SA1117,SA1401,SA1134,CS0108,CS0618,CS1998,CS8524,CS9042,IDE0060,SA1649,CS0419, - CS1573,CS1574 - + + $(WarningsNotAsErrors),SA1117,SA1401,SA1134,CS0108,CS0618,CS9042,CS1998,CS8524,IDE0060,SA1649,CS0419,CS1573,CS1574 + @@ -41,8 +46,4 @@ - - - - diff --git a/src/Umbraco.Cms.Persistence.EFCore.SqlServer/Umbraco.Cms.Persistence.EFCore.SqlServer.csproj b/src/Umbraco.Cms.Persistence.EFCore.SqlServer/Umbraco.Cms.Persistence.EFCore.SqlServer.csproj index 264cf02579..d232abc1f4 100644 --- a/src/Umbraco.Cms.Persistence.EFCore.SqlServer/Umbraco.Cms.Persistence.EFCore.SqlServer.csproj +++ b/src/Umbraco.Cms.Persistence.EFCore.SqlServer/Umbraco.Cms.Persistence.EFCore.SqlServer.csproj @@ -3,17 +3,18 @@ Umbraco CMS - Persistence - Entity Framework Core - SQL Server migrations Adds support for Entity Framework Core SQL Server migrations to Umbraco CMS. + + + + + - - - - - - + + diff --git a/src/Umbraco.Cms.Persistence.EFCore/Umbraco.Cms.Persistence.EFCore.csproj b/src/Umbraco.Cms.Persistence.EFCore/Umbraco.Cms.Persistence.EFCore.csproj index bbf03ea87a..e630dad699 100644 --- a/src/Umbraco.Cms.Persistence.EFCore/Umbraco.Cms.Persistence.EFCore.csproj +++ b/src/Umbraco.Cms.Persistence.EFCore/Umbraco.Cms.Persistence.EFCore.csproj @@ -3,24 +3,30 @@ Umbraco CMS - Persistence - Entity Framework Core Adds support for Entity Framework Core to Umbraco CMS. - - - IDE0270,CS0108,CS1998 - - + + + $(WarningsNotAsErrors),IDE0270,CS0108,CS1998 + + + + + - - - + + diff --git a/src/Umbraco.Cms.Persistence.SqlServer/Umbraco.Cms.Persistence.SqlServer.csproj b/src/Umbraco.Cms.Persistence.SqlServer/Umbraco.Cms.Persistence.SqlServer.csproj index 3868136baa..e142b81382 100644 --- a/src/Umbraco.Cms.Persistence.SqlServer/Umbraco.Cms.Persistence.SqlServer.csproj +++ b/src/Umbraco.Cms.Persistence.SqlServer/Umbraco.Cms.Persistence.SqlServer.csproj @@ -3,30 +3,39 @@ Umbraco CMS - Persistence - SQL Server Adds support for SQL Server to Umbraco CMS. + - - - SA1405,SA1121,SA1117,SA1116,IDE1006,CS0618,IDE0270,IDE0057,IDE0054,CSO618,IDE0048, - CS1574 - + + $(WarningsNotAsErrors),SA1405,SA1121,SA1117,IDE1006,CS0618,IDE0270,IDE0057,IDE0054,CSO618,IDE0048,CS1574 + + + + + - - - - - - - - + + + + + diff --git a/src/Umbraco.Cms.Persistence.Sqlite/Umbraco.Cms.Persistence.Sqlite.csproj b/src/Umbraco.Cms.Persistence.Sqlite/Umbraco.Cms.Persistence.Sqlite.csproj index 0c39c66d64..e785e94943 100644 --- a/src/Umbraco.Cms.Persistence.Sqlite/Umbraco.Cms.Persistence.Sqlite.csproj +++ b/src/Umbraco.Cms.Persistence.Sqlite/Umbraco.Cms.Persistence.Sqlite.csproj @@ -3,10 +3,15 @@ Umbraco CMS - Persistence - SQLite Adds support for SQLite to Umbraco CMS. + - - CS0114 + + $(WarningsNotAsErrors),CS0114 + diff --git a/src/Umbraco.Cms.StaticAssets/Umbraco.Cms.StaticAssets.csproj b/src/Umbraco.Cms.StaticAssets/Umbraco.Cms.StaticAssets.csproj index 2464d73cef..c3842bd167 100644 --- a/src/Umbraco.Cms.StaticAssets/Umbraco.Cms.StaticAssets.csproj +++ b/src/Umbraco.Cms.StaticAssets/Umbraco.Cms.StaticAssets.csproj @@ -4,77 +4,95 @@ Contains the static assets needed to run Umbraco CMS. true / - false + + false - - NU5123 + + $(WarningsNotAsErrors),NU5123 + + + + + - $(ProjectDir)wwwroot\umbraco - $(BasePath)\backoffice - $(BasePath)\login + ..\Umbraco.Web.UI.Client\ + wwwroot\umbraco\backoffice - - - - - + + + + - - - - + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + - + <_BackofficeAssetsBuildOutput Include="$(BackofficeAssetsPath)\**" /> - + - + - + + - + + + + + + + + ..\Umbraco.Web.UI.Login\ + wwwroot\umbraco\login + + + + + + + + + + + + + + + + + <_LoginAssetsBuildOutput Include="$(LoginAssetsPath)\**" /> + + + + + + + + + + + + diff --git a/src/Umbraco.Cms.Targets/Umbraco.Cms.Targets.csproj b/src/Umbraco.Cms.Targets/Umbraco.Cms.Targets.csproj index 71e433cc12..edda7db873 100644 --- a/src/Umbraco.Cms.Targets/Umbraco.Cms.Targets.csproj +++ b/src/Umbraco.Cms.Targets/Umbraco.Cms.Targets.csproj @@ -5,11 +5,17 @@ false false + - - IDE0270,CS0108,CS1998 + + $(WarningsNotAsErrors),IDE0270,CS0108,CS1998 + @@ -24,7 +30,7 @@ <_UmbracoCmsJsonSchemaReference>appsettings-schema.Umbraco.Cms.json <_UmbracoCmsPackageSchemaReference>umbraco-package-schema.json - NU5100;NU5128 + $(NoWarn),NU5100,NU5128 diff --git a/src/Umbraco.Core/Umbraco.Core.csproj b/src/Umbraco.Core/Umbraco.Core.csproj index abd7ea6b82..f04876c543 100644 --- a/src/Umbraco.Core/Umbraco.Core.csproj +++ b/src/Umbraco.Core/Umbraco.Core.csproj @@ -5,22 +5,36 @@ Contains the core assembly needed to run Umbraco CMS. Umbraco.Cms.Core + - - - SA1117,SA1401,SA1134,SA1649,CS0618,CS0067,SA1405,SA1600,CS0168,CS0169,CS0183,SYSLIB0045,SYSLIB0051, - SYSLIB0044,SYSLIB0023,SYSLIB0003,SA1111,SA1649,CA2017,CS0108,CS0612,CS0649,CS0672,CS1574,CS1998,CS8073, - IDE0060,IDE1006,SA1306,CS1723,CS0419 - + + $(WarningsNotAsErrors),SA1117,SA1401,SA1134,SA1649,CS0618,CS0672,SYSLIB0051,SYSLIB0044,SYSLIB0023,SYSLIB0003,SYSLIB0045,CS0067,SA1405,CS0168,CS0169,CS0183,SA1111,CA2017,CS0108,CS0612,CS0649,CS1574,CS1998,CS8073,IDE0060,IDE1006,SA1306,CS1723,CS0419 + diff --git a/src/Umbraco.Examine.Lucene/Umbraco.Examine.Lucene.csproj b/src/Umbraco.Examine.Lucene/Umbraco.Examine.Lucene.csproj index cb5bea7a3d..3e90b4649d 100644 --- a/src/Umbraco.Examine.Lucene/Umbraco.Examine.Lucene.csproj +++ b/src/Umbraco.Examine.Lucene/Umbraco.Examine.Lucene.csproj @@ -5,15 +5,23 @@ Adds Examine searching support using Lucene to Umbraco CMS. Umbraco.Cms.Infrastructure.Examine + - - CS0618 + + $(WarningsNotAsErrors),CS0618 + + + + - + diff --git a/src/Umbraco.Infrastructure/Umbraco.Infrastructure.csproj b/src/Umbraco.Infrastructure/Umbraco.Infrastructure.csproj index ccaad6ffc8..7df82c5cb0 100644 --- a/src/Umbraco.Infrastructure/Umbraco.Infrastructure.csproj +++ b/src/Umbraco.Infrastructure/Umbraco.Infrastructure.csproj @@ -5,19 +5,32 @@ Contains the infrastructure assembly needed to run Umbraco CMS. Umbraco.Cms.Infrastructure + - - - CS0618,CA1416,SA1117,SA1401,SA1134,CA2017,CS0108,SYSLIB0051,SA1649,CS1998,CS0169,CS0114,IDE0060, - SA1130,IDE1006,CS1066,CS0612,CS1574 - + + $(WarningsNotAsErrors),CS0618,CA1416,SA1117,SA1401,SA1134,CA2017,CS0108,SYSLIB0051,SA1649,CS1998,CS0169,CS0114,IDE0060,SA1130,IDE1006,CS1066,CS0612,CS1574 + $(DefineConstants);TRACE_SCOPES @@ -48,8 +61,10 @@ + - + + @@ -80,8 +95,4 @@ <_Parameter1>Umbraco.Cms.Infrastructure - - - - diff --git a/src/Umbraco.PublishedCache.HybridCache/Umbraco.PublishedCache.HybridCache.csproj b/src/Umbraco.PublishedCache.HybridCache/Umbraco.PublishedCache.HybridCache.csproj index a16dd4d5a0..da5227544d 100644 --- a/src/Umbraco.PublishedCache.HybridCache/Umbraco.PublishedCache.HybridCache.csproj +++ b/src/Umbraco.PublishedCache.HybridCache/Umbraco.PublishedCache.HybridCache.csproj @@ -1,17 +1,16 @@ - - + Umbraco.Cms.PublishedCache.HybridCache Umbraco CMS - Published cache - HybridCache Contains the published cache assembly needed to run Umbraco CMS. Umbraco.Cms.Infrastructure.HybridCache - - false + false + @@ -43,5 +42,4 @@ - diff --git a/src/Umbraco.Web.Common/Umbraco.Web.Common.csproj b/src/Umbraco.Web.Common/Umbraco.Web.Common.csproj index fba4832a78..0274d838f8 100644 --- a/src/Umbraco.Web.Common/Umbraco.Web.Common.csproj +++ b/src/Umbraco.Web.Common/Umbraco.Web.Common.csproj @@ -5,16 +5,23 @@ Contains the web assembly needed to run Umbraco CMS. Umbraco.Cms.Web.Common + - - - SA1117,SA1401,SA1134,ASP0019,CS0618,IDE0040,SA1400,SA1405,SYSLIB0051,CS0419,CS1574,SA1649 - + + $(WarningsNotAsErrors),SA1117,SA1401,SA1134,ASP0019,CS0618,SYSLIB0051,IDE0040,SA1400,SA1405,CS0419,CS1574,SA1649 + @@ -26,20 +33,22 @@ + + + - + - - - - + + + + - diff --git a/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj b/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj index d6e9a44df0..bcdebc8667 100644 --- a/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj +++ b/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj @@ -3,13 +3,18 @@ Umbraco.Cms.Web.UI false false - false + + false - - SA1119 + + $(WarningsNotAsErrors),SA1119 + diff --git a/src/Umbraco.Web.Website/Routing/SurfaceControllerMatcherPolicy.cs b/src/Umbraco.Web.Website/Routing/SurfaceControllerMatcherPolicy.cs index f2a834ca09..e2b0082cc2 100644 --- a/src/Umbraco.Web.Website/Routing/SurfaceControllerMatcherPolicy.cs +++ b/src/Umbraco.Web.Website/Routing/SurfaceControllerMatcherPolicy.cs @@ -25,8 +25,8 @@ internal class SurfaceControllerMatcherPolicy : MatcherPolicy, IEndpointSelector public Task ApplyAsync(HttpContext httpContext, CandidateSet candidates) { - ArgumentNullException.ThrowIfNull(nameof(httpContext)); - ArgumentNullException.ThrowIfNull(nameof(candidates)); + ArgumentNullException.ThrowIfNull(httpContext); + ArgumentNullException.ThrowIfNull(candidates); if (candidates.Count < 2) { diff --git a/src/Umbraco.Web.Website/Umbraco.Web.Website.csproj b/src/Umbraco.Web.Website/Umbraco.Web.Website.csproj index 3b30dacc28..2daf0785a4 100644 --- a/src/Umbraco.Web.Website/Umbraco.Web.Website.csproj +++ b/src/Umbraco.Web.Website/Umbraco.Web.Website.csproj @@ -5,17 +5,19 @@ Contains the website assembly needed to run the frontend of Umbraco CMS. Umbraco.Cms.Web.Website + - - ASP0019,CS0618,SA1401,SA1649,IDE0270,IDE1006 - - - - false + + $(WarningsNotAsErrors),ASP0019,CS0618,SA1401,SA1649,IDE1006 + diff --git a/templates/Umbraco.Templates.csproj b/templates/Umbraco.Templates.csproj index 44d073a109..19ab42d32f 100644 --- a/templates/Umbraco.Templates.csproj +++ b/templates/Umbraco.Templates.csproj @@ -9,8 +9,40 @@ true true . - NU5128 + $(NoWarn),NU5128 + + + + + + + + + + + + + + + + + + + <_TemplateJsonFiles Include="**\.template.config\template.json" Exclude="bin\**;obj\**" /> + <_TemplateJsonFiles> + $(IntermediateOutputPath)%(RelativeDir)%(Filename)%(Extension) + + + + + + <_PackageFiles Include="%(_TemplateJsonFiles.DestinationFile)"> + %(_TemplateJsonFiles.RelativeDir) + + + + UmbracoProject\Program.cs @@ -32,33 +64,4 @@ UmbracoProject\Views - - - - - - - - - - - - - - - - - <_TemplateJsonFiles Include="**\.template.config\template.json" Exclude="bin\**;obj\**" /> - <_TemplateJsonFiles> - $(IntermediateOutputPath)%(RelativeDir)%(Filename)%(Extension) - - - - - - <_PackageFiles Include="%(_TemplateJsonFiles.DestinationFile)"> - %(_TemplateJsonFiles.RelativeDir) - - - diff --git a/tests/Umbraco.TestData/Umbraco.TestData.csproj b/tests/Umbraco.TestData/Umbraco.TestData.csproj index 2b8fc3fca8..65793017f6 100644 --- a/tests/Umbraco.TestData/Umbraco.TestData.csproj +++ b/tests/Umbraco.TestData/Umbraco.TestData.csproj @@ -1,12 +1,18 @@ - - CS0618,IDE1006,IDE0057 + + $(WarningsNotAsErrors),CS0618,IDE1006,IDE0057 + + diff --git a/tests/Umbraco.Tests.Benchmarks/Umbraco.Tests.Benchmarks.csproj b/tests/Umbraco.Tests.Benchmarks/Umbraco.Tests.Benchmarks.csproj index 1c3130e0f8..0eb276ee22 100644 --- a/tests/Umbraco.Tests.Benchmarks/Umbraco.Tests.Benchmarks.csproj +++ b/tests/Umbraco.Tests.Benchmarks/Umbraco.Tests.Benchmarks.csproj @@ -5,11 +5,18 @@ false false + - - SYSLIB0021,IDE0060,CS0618,CS0649 + + $(WarningsNotAsErrors),SYSLIB0021,IDE0060,CS0618,CS0649 + diff --git a/tests/Umbraco.Tests.Common/Umbraco.Tests.Common.csproj b/tests/Umbraco.Tests.Common/Umbraco.Tests.Common.csproj index d89fa7bb10..c7b6c2b19f 100644 --- a/tests/Umbraco.Tests.Common/Umbraco.Tests.Common.csproj +++ b/tests/Umbraco.Tests.Common/Umbraco.Tests.Common.csproj @@ -7,15 +7,21 @@ true $(BaseEnablePackageValidation) + - - CS1998,CS0618,SYSLIB0012 + + $(WarningsNotAsErrors),CS1998,CS0618,SYSLIB0012 + - + diff --git a/tests/Umbraco.Tests.Integration/CompatibilitySuppressions.xml b/tests/Umbraco.Tests.Integration/CompatibilitySuppressions.xml new file mode 100644 index 0000000000..bfe4c91bd1 --- /dev/null +++ b/tests/Umbraco.Tests.Integration/CompatibilitySuppressions.xml @@ -0,0 +1,11 @@ + + + + + CP0002 + M:Umbraco.Cms.Tests.Integration.Umbraco.Infrastructure.Services.TemplateServiceTests.Deleting_Master_Template_Also_Deletes_Children + lib/net9.0/Umbraco.Tests.Integration.dll + lib/net9.0/Umbraco.Tests.Integration.dll + true + + \ No newline at end of file diff --git a/tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj b/tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj index ff867ae253..50d67af360 100644 --- a/tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj +++ b/tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj @@ -6,19 +6,27 @@ Contains helper classes for integration tests with Umbraco CMS, including all internal integration tests. Umbraco.Cms.Tests.Integration true - false - NU5100 + $(BaseEnablePackageValidation) + $(NoWarn),NU5100 + - - - SYSLIB0012,SA1117,SA1116,CS0162,CS0169,SA1134,SA1405,CS0108,CS0618,CS4014,CS1998,CS0649,CS0168 - + + $(WarningsNotAsErrors),CS0108,SYSLIB0012,CS0618,SA1116,SA1117,CS0162,CS0169,SA1134,SA1405,CS4014,CS1998,CS0649,CS0168 + @@ -240,8 +248,4 @@ MediaNavigationServiceTests.cs - - - - diff --git a/tests/Umbraco.Tests.UnitTests/Umbraco.Tests.UnitTests.csproj b/tests/Umbraco.Tests.UnitTests/Umbraco.Tests.UnitTests.csproj index fa70b2e485..8661e94e37 100644 --- a/tests/Umbraco.Tests.UnitTests/Umbraco.Tests.UnitTests.csproj +++ b/tests/Umbraco.Tests.UnitTests/Umbraco.Tests.UnitTests.csproj @@ -2,22 +2,32 @@ true Umbraco.Cms.Tests.UnitTests - false - false + - - - SYSLIB0013,CS0618,CS1998,SA1117,CS0067,CA1822,CA1416,IDE0028,SA1401,SA1405 - IDE0060,SA1405,ASP0019,CS0114,CS0661,CS0659,CS0414,CS0252,CS0612,IDE0060,IDE1006 - + + $(WarningsNotAsErrors),SYSLIB0013,CS0618,CS1998,SA1117,CS0067,CA1822,CA1416,IDE0028,SA1401,SA1405,IDE0060,ASP0019,CS0114,CS0661,CS0659,CS0414,CS0252,CS0612,IDE1006 + @@ -30,8 +40,6 @@ - - BackOfficeExternalLoginServiceTests.cs @@ -39,35 +47,4 @@ BackOfficeExternalLoginServiceTests.cs - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/tools/Umbraco.JsonSchema/Umbraco.JsonSchema.csproj b/tools/Umbraco.JsonSchema/Umbraco.JsonSchema.csproj index 3f3b81165e..91867b810d 100644 --- a/tools/Umbraco.JsonSchema/Umbraco.JsonSchema.csproj +++ b/tools/Umbraco.JsonSchema/Umbraco.JsonSchema.csproj @@ -4,11 +4,18 @@ false false + - - SA1117,SA1401,SA1134,CS9042 + + $(WarningsNotAsErrors),SA1117,SA1401,SA1134,CS9042 +