Skip to content

Commit 725f160

Browse files
ci: add workflow for generating copilot sdk v1 (#1398)
* ci: added conditions for stages * ci: setup stage for v1 copilot sdk (#1396) * ci: move php beta after v1 * ci: add generation stage for v1 copilot * ci: add version name for better PR info * chore(deps): bump actions/upload-artifact from 4 to 5 (#1397) Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 5. - [Release notes](https://github.com/actions/upload-artifact/releases) - [Commits](actions/upload-artifact@v4...v5) --- updated-dependencies: - dependency-name: actions/upload-artifact dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Michael Mainer <[email protected]> --------- Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
1 parent 3a4373a commit 725f160

File tree

2 files changed

+96
-34
lines changed

2 files changed

+96
-34
lines changed

.azure-pipelines/generation-pipeline.yml

Lines changed: 94 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -341,6 +341,7 @@ extends:
341341
and
342342
(
343343
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
344+
eq(dependencies.open_api_v1_approval.result, 'Succeeded'),
344345
in(dependencies.stage_v1_openapi.result, 'Succeeded', 'Skipped')
345346
)
346347
jobs:
@@ -383,6 +384,7 @@ extends:
383384
and
384385
(
385386
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
387+
eq(dependencies.open_api_beta_approval.result, 'Succeeded'),
386388
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
387389
)
388390
jobs:
@@ -425,6 +427,7 @@ extends:
425427
and
426428
(
427429
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
430+
eq(dependencies.open_api_v1_approval.result, 'Succeeded'),
428431
in(dependencies.stage_v1_openapi.result, 'Succeeded', 'Skipped')
429432
)
430433
jobs:
@@ -465,6 +468,7 @@ extends:
465468
and
466469
(
467470
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
471+
eq(dependencies.open_api_beta_approval.result, 'Succeeded'),
468472
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
469473
)
470474
jobs:
@@ -505,6 +509,7 @@ extends:
505509
and
506510
(
507511
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
512+
eq(dependencies.open_api_v1_approval.result, 'Succeeded'),
508513
in(dependencies.stage_v1_openapi.result, 'Succeeded', 'Skipped')
509514
)
510515
jobs:
@@ -547,6 +552,7 @@ extends:
547552
and
548553
(
549554
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
555+
eq(dependencies.open_api_beta_approval.result, 'Succeeded'),
550556
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
551557
)
552558
jobs:
@@ -580,26 +586,28 @@ extends:
580586
parameters:
581587
repoName: msgraph-beta-sdk-java
582588
namespacePath: com/microsoft/graph/beta
583-
- stage: stage_php_beta_kiota
589+
590+
- stage: stage_php_v1_kiota
584591
dependsOn:
585592
- stage_build_and_publish_kiota
586-
- stage_beta_openapi
587-
- open_api_beta_approval
593+
- stage_v1_openapi
594+
- open_api_v1_approval
588595
condition: |
589596
and
590597
(
591598
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
592-
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
599+
eq(dependencies.open_api_v1_approval.result, 'Succeeded'),
600+
in(dependencies.stage_v1_openapi.result, 'Succeeded', 'Skipped')
593601
)
594602
jobs:
595-
- job: php_beta_kiota
603+
- job: php_v1_kiota
596604
templateContext:
597605
inputs:
598606
- input: pipelineArtifact
599607
displayName: 'Downloading metadata from artifacts'
600608
buildType: 'current'
601-
artifactName: $(cleanOpenAPIFolderBeta)
602-
targetPath: '$(Build.SourcesDirectory)/msgraph-metadata/$(cleanOpenAPIFolderBeta)'
609+
artifactName: $(cleanOpenAPIFolderV1)
610+
targetPath: '$(Build.SourcesDirectory)/msgraph-metadata/$(cleanOpenAPIFolderV1)'
603611
- input: pipelineArtifact
604612
buildType: 'current'
605613
artifactName: 'kiota'
@@ -608,40 +616,41 @@ extends:
608616
- template: /.azure-pipelines/generation-templates/language-generation-kiota.yml@self
609617
parameters:
610618
language: 'php'
611-
version: 'beta'
612-
repoName: 'msgraph-beta-sdk-php'
613-
branchName: 'kiota/$(betaBranch)'
619+
version: ''
620+
repoName: 'msgraph-sdk-php'
621+
branchName: 'kiota/$(v1Branch)'
614622
targetClassName: "BaseGraphClient"
615-
targetNamespace: 'Microsoft\\Graph\\Beta\\Generated'
623+
targetNamespace: 'Microsoft\\Graph\\Generated'
616624
baseBranchName: 'main'
617625
commitMessagePrefix: "feat(generation): update request builders and models"
618-
cleanMetadataFolder: $(cleanOpenAPIFolderBeta)
626+
cleanMetadataFolder: $(cleanOpenAPIFolderV1)
619627
languageSpecificSteps:
620628
- template: /.azure-pipelines/generation-templates/php-kiota.yml@self
621629
parameters:
622-
repoName: msgraph-beta-sdk-php
630+
repoName: msgraph-sdk-php
623631
customArguments: "-b -e '/me' -e '/me/**'" # Exclude /me/** and enable backing store
624632

625-
- stage: stage_php_v1_kiota
633+
- stage: stage_php_beta_kiota
626634
dependsOn:
627635
- stage_build_and_publish_kiota
628-
- stage_v1_openapi
629-
- open_api_v1_approval
636+
- stage_beta_openapi
637+
- open_api_beta_approval
630638
condition: |
631639
and
632640
(
633641
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
634-
in(dependencies.stage_v1_openapi.result, 'Succeeded', 'Skipped')
642+
eq(dependencies.open_api_beta_approval.result, 'Succeeded'),
643+
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
635644
)
636645
jobs:
637-
- job: php_v1_kiota
646+
- job: php_beta_kiota
638647
templateContext:
639648
inputs:
640649
- input: pipelineArtifact
641650
displayName: 'Downloading metadata from artifacts'
642651
buildType: 'current'
643-
artifactName: $(cleanOpenAPIFolderV1)
644-
targetPath: '$(Build.SourcesDirectory)/msgraph-metadata/$(cleanOpenAPIFolderV1)'
652+
artifactName: $(cleanOpenAPIFolderBeta)
653+
targetPath: '$(Build.SourcesDirectory)/msgraph-metadata/$(cleanOpenAPIFolderBeta)'
645654
- input: pipelineArtifact
646655
buildType: 'current'
647656
artifactName: 'kiota'
@@ -650,18 +659,18 @@ extends:
650659
- template: /.azure-pipelines/generation-templates/language-generation-kiota.yml@self
651660
parameters:
652661
language: 'php'
653-
version: ''
654-
repoName: 'msgraph-sdk-php'
655-
branchName: 'kiota/$(v1Branch)'
662+
version: 'beta'
663+
repoName: 'msgraph-beta-sdk-php'
664+
branchName: 'kiota/$(betaBranch)'
656665
targetClassName: "BaseGraphClient"
657-
targetNamespace: 'Microsoft\\Graph\\Generated'
666+
targetNamespace: 'Microsoft\\Graph\\Beta\\Generated'
658667
baseBranchName: 'main'
659668
commitMessagePrefix: "feat(generation): update request builders and models"
660-
cleanMetadataFolder: $(cleanOpenAPIFolderV1)
669+
cleanMetadataFolder: $(cleanOpenAPIFolderBeta)
661670
languageSpecificSteps:
662671
- template: /.azure-pipelines/generation-templates/php-kiota.yml@self
663672
parameters:
664-
repoName: msgraph-sdk-php
673+
repoName: msgraph-beta-sdk-php
665674
customArguments: "-b -e '/me' -e '/me/**'" # Exclude /me/** and enable backing store
666675

667676
- stage: stage_typescript_v1
@@ -672,6 +681,7 @@ extends:
672681
and
673682
(
674683
eq(dependencies.stage_build_and_publish_typewriter.result, 'Succeeded'),
684+
eq(dependencies.open_api_v1_approval.result, 'Succeeded'),
675685
in(dependencies.stage_v1_metadata.result, 'Succeeded', 'Skipped')
676686
)
677687
jobs:
@@ -709,6 +719,7 @@ extends:
709719
and
710720
(
711721
eq(dependencies.stage_build_and_publish_typewriter.result, 'Succeeded'),
722+
eq(dependencies.open_api_beta_approval.result, 'Succeeded'),
712723
in(dependencies.stage_beta_metadata.result, 'Succeeded', 'Skipped')
713724
)
714725
jobs:
@@ -747,6 +758,7 @@ extends:
747758
and
748759
(
749760
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
761+
eq(dependencies.open_api_v1_approval.result, 'Succeeded'),
750762
in(dependencies.stage_v1_openapi.result, 'Succeeded', 'Skipped')
751763
)
752764
jobs:
@@ -790,6 +802,7 @@ extends:
790802
and
791803
(
792804
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
805+
eq(dependencies.open_api_beta_approval.result, 'Succeeded'),
793806
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
794807
)
795808
jobs:
@@ -833,6 +846,7 @@ extends:
833846
and
834847
(
835848
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
849+
eq(dependencies.open_api_v1_approval.result, 'Succeeded'),
836850
in(dependencies.stage_v1_openapi.result, 'Succeeded', 'Skipped')
837851
)
838852
jobs:
@@ -865,6 +879,7 @@ extends:
865879
parameters:
866880
repoName: msgraph-sdk-python
867881
baseDirectory: msgraph
882+
868883
- stage: stage_python_beta
869884
dependsOn:
870885
- stage_build_and_publish_kiota
@@ -874,6 +889,7 @@ extends:
874889
and
875890
(
876891
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
892+
eq(dependencies.open_api_beta_approval.result, 'Succeeded'),
877893
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
878894
)
879895
jobs:
@@ -906,7 +922,52 @@ extends:
906922
parameters:
907923
repoName: msgraph-beta-sdk-python
908924
baseDirectory: msgraph_beta
909-
- stage: stage_ccs_csharp_beta
925+
926+
- stage: stage_agents_m365copilot_csharp_v1
927+
dependsOn:
928+
- stage_build_and_publish_kiota
929+
- stage_v1_openapi
930+
condition: |
931+
and
932+
(
933+
eq(dependencies.stage_build_and_publish_kiota.result, 'Succeeded'),
934+
in(dependencies.stage_v1_openapi.result, 'Succeeded', 'Skipped')
935+
)
936+
jobs:
937+
- job: csharp_v1_agents_m365copilot
938+
templateContext:
939+
inputs:
940+
- input: pipelineArtifact
941+
displayName: 'Downloading metadata from artifacts'
942+
buildType: 'current'
943+
artifactName: $(cleanOpenAPIFolderV1)
944+
targetPath: '$(Build.SourcesDirectory)/msgraph-metadata/$(cleanOpenAPIFolderV1)'
945+
- input: pipelineArtifact
946+
buildType: 'current'
947+
artifactName: 'kiota'
948+
targetPath: '$(kiotaDirectory)'
949+
steps:
950+
- template: /.azure-pipelines/generation-templates/language-generation-kiota.yml@self
951+
parameters:
952+
language: 'csharp'
953+
version: 'v1'
954+
orgName: 'microsoft'
955+
repoName: 'Agents-M365Copilot'
956+
baseBranchName: 'main'
957+
branchName: 'ccs-dotnet/$(v1Branch)'
958+
targetClassName: "BaseAgentsM365CopilotServiceClient"
959+
targetNamespace: "Microsoft.Agents.M365Copilot"
960+
commitMessagePrefix: "feat(generation): update request builders and models for dotnet v1"
961+
customArguments: "-b -i '**/copilot/**'" # Enable the backing store, include only copilot paths
962+
cleanMetadataFolder: $(cleanOpenAPIFolderV1)
963+
pathExclusionArguments: ''
964+
languageSpecificSteps:
965+
- template: /.azure-pipelines/generation-templates/dotnet-kiota.yml@self
966+
parameters:
967+
repoName: 'Agents-M365Copilot/dotnet'
968+
packageName: Microsoft.Agents.M365Copilot
969+
970+
- stage: stage_agents_m365copilot_csharp_beta
910971
dependsOn:
911972
- stage_build_and_publish_kiota
912973
- stage_beta_openapi
@@ -917,7 +978,7 @@ extends:
917978
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
918979
)
919980
jobs:
920-
- job: csharp_beta_ccs
981+
- job: csharp_beta_agents_m365copilot
921982
templateContext:
922983
inputs:
923984
- input: pipelineArtifact
@@ -949,7 +1010,8 @@ extends:
9491010
parameters:
9501011
repoName: 'Agents-M365Copilot/dotnet'
9511012
packageName: Microsoft.Agents.M365Copilot.Beta
952-
- stage: stage_ccs_python_beta
1013+
1014+
- stage: stage_agents_m365copilot_python_beta
9531015
dependsOn:
9541016
- stage_build_and_publish_kiota
9551017
- stage_beta_openapi
@@ -960,7 +1022,7 @@ extends:
9601022
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
9611023
)
9621024
jobs:
963-
- job: python_beta_ccs
1025+
- job: python_beta_agents_m365copilot
9641026
templateContext:
9651027
inputs:
9661028
- input: pipelineArtifact
@@ -992,7 +1054,7 @@ extends:
9921054
parameters:
9931055
repoName: 'Agents-M365Copilot/python/packages'
9941056
baseDirectory: microsoft_agents_m365copilot_beta/microsoft_agents_m365copilot_beta
995-
- stage: stage_ccs_typescript_beta
1057+
- stage: stage_agents_m365copilot_typescript_beta
9961058
dependsOn:
9971059
- stage_build_and_publish_kiota
9981060
- stage_beta_openapi
@@ -1003,7 +1065,7 @@ extends:
10031065
in(dependencies.stage_beta_openapi.result, 'Succeeded', 'Skipped')
10041066
)
10051067
jobs:
1006-
- job: typescript_beta_ccs
1068+
- job: typescript_beta_agents_m365copilot
10071069
templateContext:
10081070
inputs:
10091071
- input: pipelineArtifact

.github/workflows/dotnet.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,13 +26,13 @@ jobs:
2626
- name: Test
2727
run: dotnet test ./Typewriter.sln --no-build --verbosity normal
2828
- name: Upload languages test output on failure
29-
uses: actions/upload-artifact@v4
29+
uses: actions/upload-artifact@v5
3030
if: ${{ failure() }}
3131
with:
3232
name: languages-test-output
3333
path: 'test/Typewriter.Test/bin/Debug/net8.0/OutputDirectory*/**'
3434
- name: Upload unit test output on failure
35-
uses: actions/upload-artifact@v4
35+
uses: actions/upload-artifact@v5
3636
if: ${{ failure() }}
3737
with:
3838
name: unit-test-output

0 commit comments

Comments
 (0)