Skip to content

Commit

Permalink
Temporary/sync generation to future 26565 (#26577)
Browse files Browse the repository at this point in the history
* [MSGraph] Fix parameter name bug caused by autorest powershell upgrade (#26565)

* fix name

* fix name

* adapt
  • Loading branch information
VeryEarly authored Nov 4, 2024
1 parent d7ea750 commit a08bf8c
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 22 deletions.
47 changes: 34 additions & 13 deletions src/Resources/MSGraph.Autorest/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,8 @@ directive:
- from: source-file-csharp
where: $
transform: if ($documentPath.endsWith("MSGraph.cs")) {$ = $.replace(/Count.ToString\(\)/g, "Count.ToString().ToLower()")}


# below directives are for mitigate breaking change upgrading autorest.powershell v3 -> v4
- where:
subject: ApplicationsApplication
set:
Expand All @@ -136,6 +137,38 @@ directive:
subject: (UsersUser)(.*)
set:
subject: User$2
- where:
subject: ^Application$
parameter-name: ApplicationId
set:
parameter-name: Id
alias: ApplicationId
- where:
subject: ^User$
parameter-name: UserId
set:
parameter-name: Id
alias: UserId
- where:
subject: ^ServicePrincipal$
parameter-name: ServicePrincipalId
set:
parameter-name: Id
alias: ServicePrincipalId
- where:
subject: ^Group$
verb: ^(?!Update$)
parameter-name: GroupId
set:
parameter-name: Id
alias: GroupId
- where:
subject: ^Group$
verb: ^Update$
parameter-name: GroupId
set:
parameter-name: ObjectId
alias: GroupId

# hide user owned application cmdlets
- where:
Expand Down Expand Up @@ -240,18 +273,6 @@ directive:
subject: organization
verb: New
hide: true
- where:
subject: ^group$
verb: ^Update$
parameter-name: GroupId
set:
parameter-name: ObjectId
- where:
subject: ^group$
verb: ^Update$
parameter-name: ObjectId
set:
alias: GroupId

- where:
subject: ^group$
Expand Down
2 changes: 1 addition & 1 deletion src/Resources/MSGraph.Autorest/docs/Az.MSGraph.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
Module Name: Az.MSGraph
Module Guid: dd44abe1-c90f-434a-8c2d-e7927f212461
Module Guid: 92f761e8-e4b0-424e-b6f7-146497ec7ff6
Download Help Link: https://learn.microsoft.com/powershell/module/az.msgraph
Help Version: 1.0.0.0
Locale: en-US
Expand Down
2 changes: 1 addition & 1 deletion src/Resources/MSGraph.Autorest/generate-info.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"generate_Id": "b9ad0464-6731-4e5e-a760-0d118f5e6db2"
"generate_Id": "64268d0d-979c-44ef-91e9-96b967985179"
}
12 changes: 6 additions & 6 deletions src/Resources/Resources.sln
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Az.ScheduledQueryRule", "..
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Az.Policy", "..\..\generated\Resources\Policy.Autorest\Az.Policy.csproj", "{1769C68D-5F64-4418-B90A-8F7376BE54D1}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Az.MSGraph", "..\..\generated\Resources\MSGraph.Autorest\Az.MSGraph.csproj", "{3485732B-FBF2-4FD2-ABD7-E8FE8FF65F05}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Az.DataBoundary", "..\..\generated\Resources\DataBoundary.Autorest\Az.DataBoundary.csproj", "{34DBCB85-397C-42BF-A3BE-BD0E3454960C}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Az.MSGraph", "..\..\generated\Resources\MSGraph.Autorest\Az.MSGraph.csproj", "{E198FFD2-70B2-428F-960B-E826E612F797}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -180,14 +180,14 @@ Global
{1769C68D-5F64-4418-B90A-8F7376BE54D1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{1769C68D-5F64-4418-B90A-8F7376BE54D1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{1769C68D-5F64-4418-B90A-8F7376BE54D1}.Release|Any CPU.Build.0 = Release|Any CPU
{3485732B-FBF2-4FD2-ABD7-E8FE8FF65F05}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{3485732B-FBF2-4FD2-ABD7-E8FE8FF65F05}.Debug|Any CPU.Build.0 = Debug|Any CPU
{3485732B-FBF2-4FD2-ABD7-E8FE8FF65F05}.Release|Any CPU.ActiveCfg = Release|Any CPU
{3485732B-FBF2-4FD2-ABD7-E8FE8FF65F05}.Release|Any CPU.Build.0 = Release|Any CPU
{34DBCB85-397C-42BF-A3BE-BD0E3454960C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{34DBCB85-397C-42BF-A3BE-BD0E3454960C}.Debug|Any CPU.Build.0 = Debug|Any CPU
{34DBCB85-397C-42BF-A3BE-BD0E3454960C}.Release|Any CPU.ActiveCfg = Release|Any CPU
{34DBCB85-397C-42BF-A3BE-BD0E3454960C}.Release|Any CPU.Build.0 = Release|Any CPU
{E198FFD2-70B2-428F-960B-E826E612F797}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{E198FFD2-70B2-428F-960B-E826E612F797}.Debug|Any CPU.Build.0 = Debug|Any CPU
{E198FFD2-70B2-428F-960B-E826E612F797}.Release|Any CPU.ActiveCfg = Release|Any CPU
{E198FFD2-70B2-428F-960B-E826E612F797}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{5323D4CC-D4B7-44A7-B79A-F91C47AC9650} = {23F657BD-37C1-4E91-8548-5783E43D40B0}
Expand Down
2 changes: 1 addition & 1 deletion src/Resources/Resources/Az.Resources.psd1
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#
# Generated by: Microsoft Corporation
#
# Generated on: 10/31/2024
# Generated on: 11/4/2024
#

@{
Expand Down

0 comments on commit a08bf8c

Please sign in to comment.