From 101d5ec7d7fe122fa81a377c8ab8b562d1add9ee Mon Sep 17 00:00:00 2001
From: Hugo van Kemenade <hugovk@users.noreply.github.com>
Date: Fri, 16 Jun 2023 14:04:34 +0300
Subject: [PATCH] CI: Remove docs build from Azure Pipelines (#105823)

---
 .azure-pipelines/ci.yml              | 14 ---------
 .azure-pipelines/docs-steps.yml      | 47 ----------------------------
 .azure-pipelines/pr.yml              | 12 -------
 .azure-pipelines/prebuild-checks.yml | 12 -------
 4 files changed, 85 deletions(-)
 delete mode 100644 .azure-pipelines/docs-steps.yml

diff --git a/.azure-pipelines/ci.yml b/.azure-pipelines/ci.yml
index fb4a2218ddd8d8..63252a76abb69f 100644
--- a/.azure-pipelines/ci.yml
+++ b/.azure-pipelines/ci.yml
@@ -14,20 +14,6 @@ jobs:
   - template: ./prebuild-checks.yml
 
 
-- job: Docs_PR
-  displayName: Docs PR
-  dependsOn: Prebuild
-  condition: and(succeeded(), eq(dependencies.Prebuild.outputs['docs.run'], 'true'))
-
-  pool:
-    vmImage: ubuntu-22.04
-
-  steps:
-  - template: ./docs-steps.yml
-    parameters:
-      upload: true
-
-
 - job: macOS_CI_Tests
   displayName: macOS CI Tests
   dependsOn: Prebuild
diff --git a/.azure-pipelines/docs-steps.yml b/.azure-pipelines/docs-steps.yml
deleted file mode 100644
index 647daff7a033a8..00000000000000
--- a/.azure-pipelines/docs-steps.yml
+++ /dev/null
@@ -1,47 +0,0 @@
-parameters:
-  latex: false
-  upload: false
-
-steps:
-- checkout: self
-  clean: true
-  fetchDepth: 5
-
-- task: UsePythonVersion@0
-  displayName: 'Use Python 3.6 or later'
-  inputs:
-    versionSpec: '>=3.6'
-
-- script: python -m pip install -r requirements.txt
-  workingDirectory: '$(build.sourcesDirectory)/Doc'
-  displayName: 'Install build dependencies'
-
-- ${{ if ne(parameters.latex, 'true') }}:
-  - script: make check html PYTHON=python
-    workingDirectory: '$(build.sourcesDirectory)/Doc'
-    displayName: 'Build documentation'
-
-- ${{ if eq(parameters.latex, 'true') }}:
-  - script: sudo apt-get update && sudo apt-get install -qy --force-yes texlive-full
-    displayName: 'Install LaTeX'
-
-  - script: make dist PYTHON=python SPHINXBUILD='python -m sphinx' BLURB='python -m blurb'
-    workingDirectory: '$(build.sourcesDirectory)/Doc'
-    displayName: 'Build documentation'
-
-- ${{ if eq(parameters.upload, 'true') }}:
-  - task: PublishBuildArtifacts@1
-    displayName: 'Publish docs'
-
-    inputs:
-      PathToPublish: '$(build.sourcesDirectory)/Doc/build'
-      ArtifactName: docs
-      publishLocation: Container
-
-  - ${{ if eq(parameters.latex, 'true') }}:
-    - task: PublishBuildArtifacts@1
-      displayName: 'Publish dist'
-      inputs:
-        PathToPublish: '$(build.sourcesDirectory)/Doc/dist'
-        ArtifactName: docs_dist
-        publishLocation: Container
diff --git a/.azure-pipelines/pr.yml b/.azure-pipelines/pr.yml
index b822d58806b9a6..939c9b4249a3c2 100644
--- a/.azure-pipelines/pr.yml
+++ b/.azure-pipelines/pr.yml
@@ -14,18 +14,6 @@ jobs:
   - template: ./prebuild-checks.yml
 
 
-- job: Docs_PR
-  displayName: Docs PR
-  dependsOn: Prebuild
-  condition: and(succeeded(), eq(dependencies.Prebuild.outputs['docs.run'], 'true'))
-
-  pool:
-    vmImage: ubuntu-22.04
-
-  steps:
-  - template: ./docs-steps.yml
-
-
 - job: macOS_PR_Tests
   displayName: macOS PR Tests
   dependsOn: Prebuild
diff --git a/.azure-pipelines/prebuild-checks.yml b/.azure-pipelines/prebuild-checks.yml
index 30ff642d1267a1..2c6460d2386735 100644
--- a/.azure-pipelines/prebuild-checks.yml
+++ b/.azure-pipelines/prebuild-checks.yml
@@ -11,18 +11,6 @@ steps:
   displayName: Fetch comparison tree
   condition: and(succeeded(), variables['System.PullRequest.TargetBranch'])
 
-- script: |
-   if ! git diff --name-only $(diffTarget) | grep -qE '(\.rst$|^Doc|^Misc)'
-   then
-     echo "No docs were updated: docs.run=false"
-     echo "##vso[task.setvariable variable=run;isOutput=true]false"
-   else
-     echo "Docs were updated: docs.run=true"
-     echo "##vso[task.setvariable variable=run;isOutput=true]true"
-   fi
-  displayName: Detect documentation changes
-  name: docs
-
 - script: |
    if ! git diff --name-only $(diffTarget) | grep -qvE '(\.rst$|^Doc|^Misc)'
    then