Added clean before building for "make check"
Copied over the cleaning part of OpenRA PR 20726. This is because `make check` only reports issues when doing a fresh build.
This commit is contained in:
parent
50ccec2498
commit
2451b489a6
3
Makefile
3
Makefile
@ -182,9 +182,10 @@ ifneq ("$(MOD_SOLUTION_FILES)","")
|
|||||||
@echo "Compiling in Debug mode..."
|
@echo "Compiling in Debug mode..."
|
||||||
ifeq ($(RUNTIME), mono)
|
ifeq ($(RUNTIME), mono)
|
||||||
# Enabling EnforceCodeStyleInBuild and GenerateDocumentationFile as a workaround for some code style rules (in particular IDE0005) being bugged and not reporting warnings/errors otherwise.
|
# Enabling EnforceCodeStyleInBuild and GenerateDocumentationFile as a workaround for some code style rules (in particular IDE0005) being bugged and not reporting warnings/errors otherwise.
|
||||||
@$(MSBUILD) -t:build -restore -p:Configuration=Debug -warnaserror -p:TargetPlatform=$(TARGETPLATFORM) -p:Mono=true -p:EnforceCodeStyleInBuild=true -p:GenerateDocumentationFile=true
|
@$(MSBUILD) -t:clean\;build -restore -p:Configuration=Debug -warnaserror -p:TargetPlatform=$(TARGETPLATFORM) -p:Mono=true -p:EnforceCodeStyleInBuild=true -p:GenerateDocumentationFile=true
|
||||||
else
|
else
|
||||||
# Enabling EnforceCodeStyleInBuild and GenerateDocumentationFile as a workaround for some code style rules (in particular IDE0005) being bugged and not reporting warnings/errors otherwise.
|
# Enabling EnforceCodeStyleInBuild and GenerateDocumentationFile as a workaround for some code style rules (in particular IDE0005) being bugged and not reporting warnings/errors otherwise.
|
||||||
|
@$(DOTNET) clean -c Debug --nologo --verbosity minimal
|
||||||
@$(DOTNET) build -c Debug -nologo -warnaserror -p:TargetPlatform=$(TARGETPLATFORM) -p:EnforceCodeStyleInBuild=true -p:GenerateDocumentationFile=true
|
@$(DOTNET) build -c Debug -nologo -warnaserror -p:TargetPlatform=$(TARGETPLATFORM) -p:EnforceCodeStyleInBuild=true -p:GenerateDocumentationFile=true
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|||||||
1
make.ps1
1
make.ps1
@ -119,6 +119,7 @@ function Check-Command
|
|||||||
Write-Host "Compiling $modID in Debug configuration..." -ForegroundColor Cyan
|
Write-Host "Compiling $modID in Debug configuration..." -ForegroundColor Cyan
|
||||||
|
|
||||||
# Enabling EnforceCodeStyleInBuild and GenerateDocumentationFile as a workaround for some code style rules (in particular IDE0005) being bugged and not reporting warnings/errors otherwise.
|
# Enabling EnforceCodeStyleInBuild and GenerateDocumentationFile as a workaround for some code style rules (in particular IDE0005) being bugged and not reporting warnings/errors otherwise.
|
||||||
|
dotnet clean -c Debug --nologo --verbosity minimal
|
||||||
dotnet build -c Debug --nologo -warnaserror -p:TargetPlatform=win-x64 -p:EnforceCodeStyleInBuild=true -p:GenerateDocumentationFile=true
|
dotnet build -c Debug --nologo -warnaserror -p:TargetPlatform=win-x64 -p:EnforceCodeStyleInBuild=true -p:GenerateDocumentationFile=true
|
||||||
if ($lastexitcode -ne 0)
|
if ($lastexitcode -ne 0)
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user