Skip to content

Commit

Permalink
More fix ups
Browse files Browse the repository at this point in the history
  • Loading branch information
filipnavara committed May 31, 2024
1 parent f5daa66 commit 4003602
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion generate-calendar.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
yq eval '(del(.components.schemas.[].id) | .openapi = "3.0.0" | del(.. | select(has("annotations")).annotations) | .components.schemas.EventWorkingLocationProperties.properties.homeOffice.type = "object") * load("error.yaml") | .paths.[].[]?.["responses"]? += {"4XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}} | .paths.[].[]?.["responses"]? += {"5XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}}' google-discovery-to-openapi/openapi/googleapis.com/v00.00.00000/services/calendar/calendar.yaml > src/Google.Apis.Kiota.Calendar/calendar.generated.yaml
yq eval '(del(.components.schemas.[].id) | .openapi = "3.0.0" | del(.. | select(has("annotations")).annotations) | .components.schemas.EventWorkingLocationProperties.properties.homeOffice.type = "object" | with(.. | select(.default? == "false"); .default = false) | with(.. | select(.default? == "true"); .default = true) | with(.. | select(.default? == "0"); .default = 0)) * load("error.yaml") | .paths.[].[]?.["responses"]? += {"4XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}} | .paths.[].[]?.["responses"]? += {"5XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}}' google-discovery-to-openapi/openapi/googleapis.com/v00.00.00000/services/calendar/calendar.yaml > src/Google.Apis.Kiota.Calendar/calendar.generated.yaml
kiota generate --openapi src/Google.Apis.Kiota.Calendar/calendar.generated.yaml -o src/Google.Apis.Kiota.Calendar/Generated -l CSharp -n Google.Apis.Kiota.Calendar -c CalendarApiClient -s Microsoft.Kiota.Serialization.Json.JsonSerializationWriterFactory --ds Microsoft.Kiota.Serialization.Json.JsonParseNodeFactory
rm src/Google.Apis.Kiota.Calendar/Generated/Models/GoogleApiException.cs
rm src/Google.Apis.Kiota.Calendar/Generated/Models/RequestError.cs
Expand Down
2 changes: 1 addition & 1 deletion generate-drive.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
yq eval '(del(.components.schemas.[].id) | .openapi = "3.0.0" | del(.. | select(has("annotations")).annotations)) * load("error.yaml") | .paths.[].[]?.["responses"]? += {"4XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}} | .paths.[].[]?.["responses"]? += {"5XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}}' google-discovery-to-openapi/openapi/googleapis.com/v00.00.00000/services/drive/drive.yaml > src/Google.Apis.Kiota.Drive/drive.generated.yaml
yq eval '(del(.components.schemas.[].id) | .openapi = "3.0.0" | del(.. | select(has("annotations")).annotations) | with(.. | select(.format? == "int64"); .type = "integer")) * load("error.yaml") | .paths.[].[]?.["responses"]? += {"4XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}} | .paths.[].[]?.["responses"]? += {"5XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}}' google-discovery-to-openapi/openapi/googleapis.com/v00.00.00000/services/drive/drive.yaml > src/Google.Apis.Kiota.Drive/drive.generated.yaml
kiota generate --openapi src/Google.Apis.Kiota.Drive/drive.generated.yaml -o src/Google.Apis.Kiota.Drive/Generated -l CSharp -n Google.Apis.Kiota.Drive -c DriveApiClient -s Microsoft.Kiota.Serialization.Json.JsonSerializationWriterFactory --ds Microsoft.Kiota.Serialization.Json.JsonParseNodeFactory
rm src/Google.Apis.Kiota.Drive/Generated/Models/GoogleApiException.cs
rm src/Google.Apis.Kiota.Drive/Generated/Models/RequestError.cs
Expand Down
2 changes: 1 addition & 1 deletion generate-gmail.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
yq eval '(del(.components.schemas.[].id) | .openapi = "3.0.0" | del(.. | select(has("annotations")).annotations) | del(.. | select(has("enumDescriptions")).enumDescriptions)) * load("error.yaml") | .paths.[].[]?.["responses"]? += {"4XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}} | .paths.[].[]?.["responses"]? += {"5XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}}' google-discovery-to-openapi/openapi/googleapis.com/v00.00.00000/services/gmail/gmail.yaml > src/Google.Apis.Kiota.Gmail/gmail.generated.yaml
yq eval '(del(.components.schemas.[].id) | .openapi = "3.0.0" | del(.. | select(has("annotations")).annotations) | del(.. | select(has("enumDescriptions")).enumDescriptions) | with(.. | select(.format? == "int64"); .type = "integer") | with(.. | select(.format? == "uint64"); .type = "integer")) * load("error.yaml") | .paths.[].[]?.["responses"]? += {"4XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}} | .paths.[].[]?.["responses"]? += {"5XX":{"description":"Failure response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GoogleApiException"}}}}}' google-discovery-to-openapi/openapi/googleapis.com/v00.00.00000/services/gmail/gmail.yaml > src/Google.Apis.Kiota.Gmail/gmail.generated.yaml
kiota generate --openapi src/Google.Apis.Kiota.Gmail/gmail.generated.yaml -o src/Google.Apis.Kiota.Gmail/Generated -l CSharp -n Google.Apis.Kiota.Gmail -c GmailApiClient -s Microsoft.Kiota.Serialization.Json.JsonSerializationWriterFactory --ds Microsoft.Kiota.Serialization.Json.JsonParseNodeFactory
rm src/Google.Apis.Kiota.Gmail/Generated/Models/GoogleApiException.cs
rm src/Google.Apis.Kiota.Gmail/Generated/Models/RequestError.cs
Expand Down

0 comments on commit 4003602

Please sign in to comment.