Skip to content

Commit 88981ee

Browse files
authored
ADO CI, rm variables (#213)
This pull request updates the CI pipeline configuration in `.azdo/ci.yaml` to simplify variable usage and streamline build, test, and packaging steps. The main changes focus on removing unused variables, switching to direct script commands for testing and packaging, and ensuring consistent use of the `Release` configuration. **Pipeline configuration simplification:** * Removed the `variables` section (`buildConfiguration`, `workingDirectory`) to reduce complexity and hardcoded the `Release` configuration in build/test/pack steps. **Build, test, and packaging process updates:** * Changed the `dotnet build` step to use the `Release` configuration directly, eliminating reliance on pipeline variables. * Replaced the NuGet pack task (`DotNetCoreCLI@2`) with a direct `dotnet pack` script command, improving clarity and maintainability. * Added an explicit `dotnet test` step to run tests after building, ensuring code quality before packaging. * Updated the pack step to use the output directory and symbol package format directly in the script command for consistency.
1 parent 0e6c9ba commit 88981ee

File tree

1 file changed

+6
-18
lines changed

1 file changed

+6
-18
lines changed

.azdo/ci.yaml

Lines changed: 6 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,6 @@ pr:
77
pool:
88
vmImage: 'ubuntu-22.04'
99

10-
variables:
11-
buildConfiguration: 'Release'
12-
workingDirectory: 'botbuilder-dotnet'
13-
1410
stages:
1511
- stage: Build_Test_Pack
1612
jobs:
@@ -27,22 +23,14 @@ stages:
2723
- script: dotnet restore
2824
displayName: 'Restore'
2925

30-
- script: dotnet build --configuration $(buildConfiguration) --no-restore
26+
- script: dotnet build --no-restore --configuration Release
3127
displayName: 'Build'
32-
33-
- task: DotNetCoreCLI@2
34-
displayName: 'Pack NuGet Packages'
35-
inputs:
36-
command: pack
37-
packagesToPack: 'Microsoft.Teams.sln'
38-
packDirectory: '$(Build.ArtifactStagingDirectory)'
39-
includesymbols: false
40-
nobuild: true
41-
configuration: '$(buildConfiguration)'
42-
versioningScheme: 'byEnvVar'
43-
versionEnvVar: 'Version'
44-
buildProperties: 'SymbolPackageFormat=snupkg'
4528

29+
- script: dotnet test --no-build --configuration Release
30+
displayName: 'Test'
31+
32+
- script: dotnet pack --no-build -o $(Build.ArtifactStagingDirectory) /p:SymbolPackageFormat=snupkg --configuration Release
33+
displayName: 'Pack'
4634

4735
- task: NuGetCommand@2
4836
displayName: 'Push NuGet Packages'

0 commit comments

Comments
 (0)