From 107f005405ab5c54dcee42443778a086e1fb63c0 Mon Sep 17 00:00:00 2001 From: Joseph Petersen Date: Wed, 5 Feb 2020 23:49:00 +0100 Subject: [PATCH 1/2] add dotnet format azure pipeline --- azure-pipelines.yml | 8 ++++++++ build/stages/format.yml | 10 ++++++++++ 2 files changed, 18 insertions(+) create mode 100644 build/stages/format.yml diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 0345b29b99..8ea30c5a19 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -33,6 +33,14 @@ stages: steps: - template: build/stages/test.yml +- stage: format + jobs: + - job: format + pool: + vmImage: 'ubuntu-latest' + steps: + - template: build/stages/format.yml + - stage: Artifact_Test displayName: 'Artifacts test' dependsOn: diff --git a/build/stages/format.yml b/build/stages/format.yml new file mode 100644 index 0000000000..051e5c8d07 --- /dev/null +++ b/build/stages/format.yml @@ -0,0 +1,10 @@ +steps: +- task: UseDotNet@2 + displayName: 'Use .NET Core sdk 2.1' + inputs: + packageType: sdk + version: 2.1.803 +- script: dotnet tool install -g dotnet-format + displayName: Install DotNet Format +- script: dotnet format --folder ./ --dry-run --check + displayName: Run DotNet Format From c3f6dd0302c0e2b5143923f43cdf8bccdfcc3cba Mon Sep 17 00:00:00 2001 From: Joseph Petersen Date: Wed, 5 Feb 2020 23:51:58 +0100 Subject: [PATCH 2/2] add depends on --- azure-pipelines.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 8ea30c5a19..ee8a30c275 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -33,9 +33,10 @@ stages: steps: - template: build/stages/test.yml -- stage: format +- stage: Format + dependsOn: [] jobs: - - job: format + - job: Format pool: vmImage: 'ubuntu-latest' steps: