parameters:
  IsStableRelease: false

steps:
- task: DownloadBuildArtifacts@0
  displayName: 'Download all bundles'
  inputs:
    downloadType: specific
    itemPattern: 'bundles/*'
    downloadPath: '$(Build.ArtifactStagingDirectory)'
- ${{ if eq(parameters.IsStableRelease, true) }}:
  - script: |
      touch .is_stable
    displayName: 'Mark as stable release'
- script: |
    set -ex
    ./azure-pipelines/manifest.sh ../a/bundles/
    mkdir -p bundles
    mv manifest.yaml bundles/
  displayName: 'Create manifest.yaml'
