Skip to content
Permalink
Browse files

CI Improvements (#81)

* Explicitly setting the repo to use 3.0.100-preview7-012821 rather than latest

* Reducing the azure-pipelines file size by using templates

* Updating the azure-pipelines to collection package artifacts

* Changing the package output path so all packages go to the same folder.

* Setting RuntimeIdentifier for ubuntu again.
  • Loading branch information...
tannergooding committed Aug 10, 2019
1 parent b15d4a7 commit cc9131f3a58bd24979ba36fee5c9d7311bb8d8fe
Showing with 114 additions and 95 deletions.
  1. +1 −1 Directory.Build.props
  2. +55 −92 scripts/azure-pipelines.yml
  3. +29 −0 scripts/azure-unix.yml
  4. +27 −0 scripts/azure-windows.yml
  5. +1 −1 scripts/build.ps1
  6. +1 −1 scripts/build.sh
@@ -38,7 +38,7 @@
<Authors>Microsoft and Contributors</Authors> <Authors>Microsoft and Contributors</Authors>
<BaseOutputPath>$(BaseArtifactsPath)bin/$(BaseArtifactsPathSuffix)/</BaseOutputPath> <BaseOutputPath>$(BaseArtifactsPath)bin/$(BaseArtifactsPathSuffix)/</BaseOutputPath>
<Company>Microsoft</Company> <Company>Microsoft</Company>
<PackageOutputPath>$(BaseArtifactsPath)pkg/$(BaseArtifactsPathSuffix)/$(Configuration)/</PackageOutputPath> <PackageOutputPath>$(BaseArtifactsPath)pkg/$(Configuration)/</PackageOutputPath>
<Product>ClangSharp</Product> <Product>ClangSharp</Product>
<VersionPrefix>8.0.0</VersionPrefix> <VersionPrefix>8.0.0</VersionPrefix>
<VersionSuffix>alpha</VersionSuffix> <VersionSuffix>alpha</VersionSuffix>
@@ -5,97 +5,60 @@ pr:
- master - master


jobs: jobs:
- job: windows - template: azure-windows.yml
pool: parameters:
name: Hosted name: windows_debug_x86
demands: Cmd pool: Hosted
strategy: configuration: Debug
matrix: architecture: x86
debug_x86:
_configuration: Debug
_architecture: x86
debug_x64:
_configuration: Debug
_architecture: x64
release_x86:
_configuration: Release
_architecture: x86
release_x64:
_configuration: Release
_architecture: x64
steps:
- task: BatchScript@1
displayName: 'Run scripts/cibuild.cmd'
inputs:
filename: scripts/cibuild.cmd
arguments: '-configuration $(_configuration) -architecture $(_architecture)'
- task: PublishTestResults@2
displayName: 'Publish Test Results'
inputs:
testResultsFormat: VSTest
testResultsFiles: artifacts/tst/$(_configuration)/*.trx
mergeTestResults: true
failTaskOnFailedTests: true
testRunTitle: 'Windows $(_configuration) $(_architecture)'
buildConfiguration: $(_configuration)
buildPlatform: $(_architecture)


- job: ubuntu_1604 - template: azure-windows.yml
pool: parameters:
name: Hosted Ubuntu 1604 name: windows_release_x86
strategy: pool: Hosted
matrix: configuration: Release
debug_x64: architecture: x86
_configuration: Debug
_architecture: x64
release_x64:
_configuration: Release
_architecture: x64
variables:
RuntimeIdentifier: ubuntu.16.04-$(_architecture)
steps:
- task: Bash@3
displayName: 'Run scripts/cibuild.sh'
inputs:
targetType: filePath
filePath: ./scripts/cibuild.sh
arguments: '--configuration $(_configuration) --architecture $(_architecture)'
- task: PublishTestResults@2
displayName: 'Publish Test Results'
inputs:
testResultsFormat: VSTest
testResultsFiles: artifacts/tst/$(_configuration)/*.trx
mergeTestResults: true
failTaskOnFailedTests: true
testRunTitle: 'Ubuntu 16.04 $(_configuration) $(_architecture)'
buildConfiguration: $(_configuration)
buildPlatform: $(_architecture)


- job: macos_1014 - template: azure-windows.yml
pool: parameters:
name: Hosted macOS name: windows_debug_x64
strategy: pool: Hosted
matrix: configuration: Debug
debug_x64: architecture: x64
_configuration: Debug
_architecture: x64 - template: azure-windows.yml
release_x64: parameters:
_configuration: Release name: windows_release_x64
_architecture: x64 pool: Hosted
steps: configuration: Release
- task: Bash@3 architecture: x64
displayName: 'Run scripts/cibuild.sh'
inputs: - template: azure-unix.yml
targetType: filePath parameters:
filePath: ./scripts/cibuild.sh name: ubuntu_debug_x64
arguments: '--configuration $(_configuration) --architecture $(_architecture)' pool: Hosted Ubuntu 1604
- task: PublishTestResults@2 configuration: Debug
displayName: 'Publish Test Results' architecture: x64
inputs: rid: ubuntu.16.04-x64
testResultsFormat: VSTest
testResultsFiles: artifacts/tst/$(_configuration)/*.trx - template: azure-unix.yml
mergeTestResults: true parameters:
failTaskOnFailedTests: true name: ubuntu_release_x64
testRunTitle: 'MacOS 10.14 $(_configuration) $(_architecture)' pool: Hosted Ubuntu 1604
buildConfiguration: $(_configuration) configuration: Release
buildPlatform: $(_architecture) architecture: x64
rid: ubuntu.16.04-x64

- template: azure-unix.yml
parameters:
name: macos_debug_x64
pool: Hosted macOS
configuration: Debug
architecture: x64

- template: azure-unix.yml
parameters:
name: macos_release_x64
pool: Hosted macOS
configuration: Release
architecture: x64
@@ -0,0 +1,29 @@
jobs:
- job: ${{parameters.name}}
pool:
name: ${{parameters.pool}}
steps:
- task: Bash@3
displayName: 'Run scripts/cibuild.sh'
inputs:
targetType: filePath
filePath: ./scripts/cibuild.sh
arguments: '--configuration ${{parameters.configuration}} --architecture ${{parameters.architecture}}'
- task: PublishTestResults@2
displayName: 'Publish Test Results'
inputs:
testResultsFormat: VSTest
testResultsFiles: artifacts/tst/${{parameters.configuration}}/*.trx
mergeTestResults: true
failTaskOnFailedTests: true
testRunTitle: '${{parameters.name}}'
buildConfiguration: ${{parameters.configuration}}
buildPlatform: ${{parameters.architecture}}
- task: PublishBuildArtifacts@1
displayName: 'Publish NuGet Packages'
inputs:
PathtoPublish: artifacts/pkg/${{parameters.configuration}}
ArtifactName: packages
publishLocation: Container
variables:
RuntimeIdentifier: ${{parameters.rid}}
@@ -0,0 +1,27 @@
jobs:
- job: ${{parameters.name}}
pool:
name: ${{parameters.pool}}
demands: Cmd
steps:
- task: BatchScript@1
displayName: 'Run scripts/cibuild.cmd'
inputs:
filename: scripts/cibuild.cmd
arguments: '-configuration ${{parameters.configuration}} -architecture ${{parameters.architecture}}'
- task: PublishTestResults@2
displayName: 'Publish Test Results'
inputs:
testResultsFormat: VSTest
testResultsFiles: artifacts/tst/${{parameters.configuration}}/*.trx
mergeTestResults: true
failTaskOnFailedTests: true
testRunTitle: '${{parameters.name}}'
buildConfiguration: ${{parameters.configuration}}
buildPlatform: ${{parameters.architecture}}
- task: PublishBuildArtifacts@1
displayName: 'Publish NuGet Packages'
inputs:
PathtoPublish: artifacts/pkg/${{parameters.configuration}}
ArtifactName: packages
publishLocation: Container
@@ -120,7 +120,7 @@ try {
$DotNetInstallDirectory = Join-Path -Path $ArtifactsDir -ChildPath "dotnet" $DotNetInstallDirectory = Join-Path -Path $ArtifactsDir -ChildPath "dotnet"
Create-Directory -Path $DotNetInstallDirectory Create-Directory -Path $DotNetInstallDirectory


& $DotNetInstallScript -Channel release/3.0.1xx -Version latest -InstallDir $DotNetInstallDirectory -Architecture $architecture & $DotNetInstallScript -Channel release/3.0.1xx -Version 3.0.100-preview7-012821 -InstallDir $DotNetInstallDirectory -Architecture $architecture
& $DotNetInstallScript -Channel 2.1 -Version latest -InstallDir $DotNetInstallDirectory -Architecture $architecture -Runtime dotnet & $DotNetInstallScript -Channel 2.1 -Version latest -InstallDir $DotNetInstallDirectory -Architecture $architecture -Runtime dotnet
& $DotNetInstallScript -Channel 2.0 -Version latest -InstallDir $DotNetInstallDirectory -Architecture $architecture -Runtime dotnet & $DotNetInstallScript -Channel 2.0 -Version latest -InstallDir $DotNetInstallDirectory -Architecture $architecture -Runtime dotnet


@@ -204,7 +204,7 @@ if [[ ! -z "$architecture" ]]; then
DotNetInstallDirectory="$ArtifactsDir/dotnet" DotNetInstallDirectory="$ArtifactsDir/dotnet"
CreateDirectory "$DotNetInstallDirectory" CreateDirectory "$DotNetInstallDirectory"


. "$DotNetInstallScript" --channel release/3.0.1xx --version latest --install-dir "$DotNetInstallDirectory" --architecture "$architecture" . "$DotNetInstallScript" --channel release/3.0.1xx --version 3.0.100-preview7-012821 --install-dir "$DotNetInstallDirectory" --architecture "$architecture"
. "$DotNetInstallScript" --channel 2.1 --version latest --install-dir "$DotNetInstallDirectory" --architecture "$architecture" --runtime dotnet . "$DotNetInstallScript" --channel 2.1 --version latest --install-dir "$DotNetInstallDirectory" --architecture "$architecture" --runtime dotnet
. "$DotNetInstallScript" --channel 2.0 --version latest --install-dir "$DotNetInstallDirectory" --architecture "$architecture" --runtime dotnet . "$DotNetInstallScript" --channel 2.0 --version latest --install-dir "$DotNetInstallDirectory" --architecture "$architecture" --runtime dotnet


0 comments on commit cc9131f

Please sign in to comment.
You can’t perform that action at this time.