From 64699c8c0b5598b71fa94041797bc98d3afc8863 Mon Sep 17 00:00:00 2001 From: Benjamin Evenson <2031163+benjiro@users.noreply.github.com> Date: Tue, 27 Feb 2024 05:54:36 +1000 Subject: [PATCH] chore: Enforce coding styles on build (#242) ## This PR A follow on from the previous PR that removed unused using, this will make sure it won't occur in the future. https://github.com/open-feature/dotnet-sdk/pull/240#issuecomment-1956892758 - Enforce code styles on build - Error on unused usings - Apply workaround for IDE0005 rule ### Related Issues Fixes https://github.com/open-feature/dotnet-sdk/pull/240#issuecomment-1956892758 Signed-off-by: Benjamin Evenson <2031163+benjiro@users.noreply.github.com> Co-authored-by: Todd Baert --- .editorconfig | 5 ++--- build/Common.props | 3 +++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/.editorconfig b/.editorconfig index 2682e4d6..8a0e850a 100644 --- a/.editorconfig +++ b/.editorconfig @@ -140,14 +140,13 @@ dotnet_diagnostic.IDE0001.severity = warning dotnet_diagnostic.IDE0002.severity = warning # IDE0005: Remove unnecessary import -# Workaround for https://github.com/dotnet/roslyn/issues/41640 -dotnet_diagnostic.IDE0005.severity = none +dotnet_diagnostic.IDE0005.severity = error # RS0041: Public members should not use oblivious types dotnet_diagnostic.RS0041.severity = suggestion # CA2007: Do not directly await a Task -dotnet_diagnostic.CA2007.severity = error +dotnet_diagnostic.CA2007.severity = errorgit [obj/**.cs] generated_code = true diff --git a/build/Common.props b/build/Common.props index b0700847..8468f7d2 100644 --- a/build/Common.props +++ b/build/Common.props @@ -3,6 +3,9 @@ latest true true + true + + EnableGenerateDocumentationFile