parameters:
- name: ScanPath
  type: string
  default: ''
  # Where ScanPath takes a single path, ScanPaths takes a comma separated list of paths to scan
- name: ScanPaths
  type: string
  default: ''
- name: RepoRoot
  type: string
  default: $(Build.SourcesDirectory)
- name: SettingsPath
  type: string
  default: '$(Build.SourcesDirectory)/eng/.docsettings.yml'
- name: DocWardenVersion
  type: string
  default: ''

steps:
- task: PowerShell@2
  displayName: "Verify Readmes"
  inputs:
    filePath: "eng/common/scripts/Verify-Readme.ps1"
    arguments: >
      -DocWardenVersion '${{ parameters.DocWardenVersion }}'
      -ScanPaths '${{ coalesce(parameters.ScanPath, parameters.ScanPaths) }}'
      -RepoRoot ${{ parameters.RepoRoot }}
      -SettingsPath ${{ parameters.SettingsPath }}
    pwsh: true