Skip to content

Commit

Permalink
Unify the typespec options to kebab-case style (#2960)
Browse files Browse the repository at this point in the history
* update config name style

* update options

* fix ci

* update tspconfig

* update

* format

* update

* format

* update

* update config

* update config

* fix ci

* support both config

* update package details config

* update doc

* update

* update ut config

* update

* revert change

* regen code

* update modular unit test

* add option warning

* fix ci

* update

* update

* update

* update reportCamelOptionDiagnostic

* update

* update

* fix ci

* update

* update

* update

* update getPackageDetail

* Revert "update getPackageDetail"

This reverts commit 8273664.

* update

* regen widget_dpg smoke

* update

* Remove useless definition

---------

Co-authored-by: Mary Gao <[email protected]>
Co-authored-by: Qiaoqiao Zhang <[email protected]>
  • Loading branch information
3 people authored Feb 28, 2025
1 parent 7da1005 commit 26a7f7d
Show file tree
Hide file tree
Showing 292 changed files with 2,623 additions and 2,126 deletions.
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
emit: ["@azure-tools/typespec-ts"]
options:
"@azure-tools/typespec-ts":
typespecTitleMap:
typespec-title-map:
NetworkAnalyticsClient: NetworkAnalyticsApi
examples-directory: "{project-root}/spec/examples"
generateMetadata: true
generateTest: true
azureSdkForJs: false
experimentalExtensibleEnums: true
"emitter-output-dir": "{project-root}/generated/typespec-ts/sdk/test/arm-test"
packageDetails:
generate-metadata: true
generate-test: true
azure-sdk-for-js: false
experimental-extensible-enums: true
emitter-output-dir: "{project-root}/generated/typespec-ts/sdk/test/arm-test"
package-details:
name: "@azure/arm-networkanalytics"
14 changes: 7 additions & 7 deletions packages/typespec-test/test/ai/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ emit:
- "@azure-tools/typespec-ts"
options:
"@azure-tools/typespec-ts":
"emitter-output-dir": "{project-root}/generated/typespec-ts"
isModularLibrary: true
generateTest: false
azureSdkForJs: false
generateMetadata: true
"filter-out-core-models": false
packageDetails:
emitter-output-dir: "{project-root}/generated/typespec-ts"
is-modular-library: true
generate-test: false
azure-sdk-for-js: false
generate-metadata: true
filter-out-core-models: false
package-details:
name: "@azure/ai-client"
flavor: azure
linter:
Expand Down
14 changes: 7 additions & 7 deletions packages/typespec-test/test/anomalyDetector/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ emit:
- "@azure-tools/typespec-autorest"
options:
"@azure-tools/typespec-ts":
generateMetadata: true
azureSdkForJs: false
enableModelNamespace: true
isModularLibrary: true
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
generate-metadata: true
azure-sdk-for-js: false
enable-model-namespace: true
is-modular-library: true
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@msinternal/ai-anomaly-detector"
description: "A generated SDK for AnomalyDetectorRest."
version: "1.0.0-beta.1"
"@azure-tools/typespec-autorest":
"emitter-output-dir": "{project-root}/generated/openapi"
emitter-output-dir: "{project-root}/generated/openapi"
10 changes: 5 additions & 5 deletions packages/typespec-test/test/authoring/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ emit:
- "@azure-tools/typespec-autorest"
options:
"@azure-tools/typespec-autorest":
"emitter-output-dir": "{project-root}/generated/openapi"
emitter-output-dir: "{project-root}/generated/openapi"
"@azure-tools/typespec-ts":
azureSdkForJs: false
generateSample: true
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
azure-sdk-for-js: false
generate-sample: true
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@msinternal/authoring"
description: "Authoring Ledger Service"
16 changes: 8 additions & 8 deletions packages/typespec-test/test/batch_modular/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ emit:
options:
"@azure-tools/typespec-ts":
title: Batch Service
generateMetadata: true
generateTest: true
azureSdkForJs: false
isModularLibrary: true
hierarchyClient: false
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
generate-metadata: true
generate-test: true
azure-sdk-for-js: false
is-modular-library: true
hierarchy-client: false
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@azure-rest/batch"
description: "Batch Service"
version: "1.0.0-beta.1"
version: "1.0.0-beta.1"
10 changes: 5 additions & 5 deletions packages/typespec-test/test/chatApi_modular/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ emit:
- "@azure-tools/typespec-ts"
options:
"@azure-tools/typespec-ts":
azureSdkForJs: false
isModularLibrary: true
"emitter-output-dir": "{project-root}/generated/typespec-ts"
hierarchyClient: false
packageDetails:
azure-sdk-for-js: false
is-modular-library: true
emitter-output-dir: "{project-root}/generated/typespec-ts"
hierarchy-client: false
package-details:
name: "@azure/ai-chat-protocol"
12 changes: 6 additions & 6 deletions packages/typespec-test/test/confidentialLedger/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ emit:
- "@azure-tools/typespec-autorest"
options:
"@azure-tools/typespec-ts":
azureSdkForJs: false
generateMetadata: true
generateTest: false
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
azure-sdk-for-js: false
generate-metadata: true
generate-test: false
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@msinternal/confidential-ledger"
description: "Confidential Ledger Service"
"@azure-tools/typespec-autorest":
"emitter-output-dir": "{project-root}/generated/openapi"
emitter-output-dir: "{project-root}/generated/openapi"
16 changes: 8 additions & 8 deletions packages/typespec-test/test/contentsafety_modular/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ emit:
options:
"@azure-tools/typespec-ts":
title: ContentSafety Service
generateMetadata: true
generateTest: false
azureSdkForJs: false
isModularLibrary: true
hierarchyClient: false
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
generate-metadata: true
generate-test: false
azure-sdk-for-js: false
is-modular-library: true
hierarchy-client: false
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@azure-rest/ai-content-safety"
version: "1.0.0"
description: "ContentSafety Service"
description: "ContentSafety Service"
8 changes: 4 additions & 4 deletions packages/typespec-test/test/contoso/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ emit:
- "@azure-tools/typespec-autorest"
options:
"@azure-tools/typespec-autorest":
"emitter-output-dir": "{project-root}/generated/openapi"
emitter-output-dir: "{project-root}/generated/openapi"
"@azure-tools/typespec-ts":
"emitter-output-dir": "{project-root}/generated/typespec-ts"
azureSdkForJs: false
packageDetails:
emitter-output-dir: "{project-root}/generated/typespec-ts"
azure-sdk-for-js: false
package-details:
name: "@azure-rest/contosowidgetmanager-rest"
description: "Contoso WidgetManager Service"
6 changes: 3 additions & 3 deletions packages/typespec-test/test/customWrapper/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@ emit:
- "@azure-tools/typespec-ts"
options:
"@azure-tools/typespec-ts":
azureSdkForJs: false
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
azure-sdk-for-js: false
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@msinternal/customWrapper"
description: "Custom Wrapper Service"
10 changes: 5 additions & 5 deletions packages/typespec-test/test/eventgrid_modular/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,11 @@ emit:
options:
"@azure-tools/typespec-ts":
title: EventGrid Service
generateMetadata: true
azureSdkForJs: false
isModularLibrary: true
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
generate-metadata: true
azure-sdk-for-js: false
is-modular-library: true
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@msinternal/eventgrid"
description: "Azure EventGrid"
version: "1.0.0-beta.1"
10 changes: 5 additions & 5 deletions packages/typespec-test/test/faceai/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ emit:
- "@azure-tools/typespec-ts"
options:
"@azure-tools/typespec-ts":
generateMetadata: true
generateTest: true
azureSdkForJs: false
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
generate-metadata: true
generate-test: true
azure-sdk-for-js: false
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@azure-rest/ai-face-rest"
description: "Face API REST Client"
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
emit: ["@azure-tools/typespec-ts"]
options:
"@azure-tools/typespec-ts":
generateMetadata: true
generateTest: true
generateSample: true
azureSdkForJs: false
isModularLibrary: true
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
generate-metadata: true
generate-test: true
generate-sample: true
azure-sdk-for-js: false
is-modular-library: true
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@azure-rest/health-insights-radiologyinsights"
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ options:
# package-name: "azure-healthinsights-clinicalmatching"
"@azure-tools/typespec-ts":
title: Health Insights Clinical Matching
generateMetadata: true
generateTest: true
generateSample: true
azureSdkForJs: false
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
generate-metadata: true
generate-test: true
generate-sample: true
azure-sdk-for-js: false
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@azure-rest/health-insights-clinicalmatching"
description: "Azure Health Insights ClinicalMatching"
version: "1.0.0-beta.1"
8 changes: 4 additions & 4 deletions packages/typespec-test/test/hierarchy_generic/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ emit:
- "@azure-tools/typespec-ts"
options:
"@azure-tools/typespec-ts":
azureSdkForJs: false
isModularLibrary: true
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
azure-sdk-for-js: false
is-modular-library: true
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@msinternal/hierarchy-generic"
description: "OpenAI"
16 changes: 8 additions & 8 deletions packages/typespec-test/test/loadTest/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,17 @@ options:
# azure-resource-provider-folder: "data-plane"
# examples-directory: ./examples
"@azure-tools/typespec-ts":
"emitter-output-dir": "{project-root}/generated/typespec-ts"
emitter-output-dir: "{project-root}/generated/typespec-ts"
title: Azure Load Testing
description: Azure Load Testing Client
generateMetadata: true
generateTest: true
generateSample: true
azureSdkForJs: false
enableOperationGroup: true
packageDetails:
generate-metadata: true
generate-test: true
generate-sample: true
azure-sdk-for-js: false
enable-operation-group: true
package-details:
name: "@azure-rest/load-testing"
description: "This package contains Microsoft Azure LoadTestingClient client library."
version: 1.0.1
# "@azure-tools/typespec-autorest":
# "emitter-output-dir": "{project-root}/generated/openapi"
# emitter-output-dir: "{project-root}/generated/openapi"
14 changes: 7 additions & 7 deletions packages/typespec-test/test/loadtesting_modular/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,15 @@ emit:
- "@azure-tools/typespec-ts"
options:
"@azure-tools/typespec-ts":
"emitter-output-dir": "{project-root}/generated/typespec-ts"
emitter-output-dir: "{project-root}/generated/typespec-ts"
title: Azure Load Testing
description: Azure Load Testing Client
azureSdkForJs: false
enableOperationGroup: true
isModularLibrary: true
hierarchyClient: false
experimentalExtensibleEnums: true
packageDetails:
azure-sdk-for-js: false
enable-operation-group: true
is-modular-library: true
hierarchy-client: false
experimental-extensible-enums: true
package-details:
name: "@azure/load-testing"
description: This package contains Microsoft Azure LoadTestingClient client library.
version: 1.0.1
14 changes: 7 additions & 7 deletions packages/typespec-test/test/openai/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ emit:
- "@azure-tools/typespec-autorest"
options:
"@azure-tools/typespec-ts":
generateMetadata: true
generateTest: true
generateSample: true
azureSdkForJs: false
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
generate-metadata: true
generate-test: true
generate-sample: true
azure-sdk-for-js: false
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@msinternal/openai"
description: "OpenAI Inference Service"
version: "1.0.0-beta.1"
"@azure-tools/typespec-autorest":
"emitter-output-dir": "{project-root}/generated/openapi"
emitter-output-dir: "{project-root}/generated/openapi"
8 changes: 4 additions & 4 deletions packages/typespec-test/test/openai_generic/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ emit:
- "@azure-tools/typespec-ts"
options:
"@azure-tools/typespec-ts":
isModularLibrary: true
"emitter-output-dir": "{project-root}/generated/typespec-ts"
ignorePropertyNameNormalize: true
packageDetails:
is-modular-library: true
emitter-output-dir: "{project-root}/generated/typespec-ts"
ignore-property-name-normalize: true
package-details:
name: "@msinternal/openai-generic"
description: "OpenAI"
10 changes: 5 additions & 5 deletions packages/typespec-test/test/openai_modular/tspconfig.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ emit:
- "@azure-tools/typespec-ts"
options:
"@azure-tools/typespec-ts":
azureSdkForJs: false
isModularLibrary: true
hierarchyClient: false
"emitter-output-dir": "{project-root}/generated/typespec-ts"
packageDetails:
azure-sdk-for-js: false
is-modular-library: true
hierarchy-client: false
emitter-output-dir: "{project-root}/generated/typespec-ts"
package-details:
name: "@msinternal/openai_modular"
description: "OpenAI Inference Service"
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ emit:
- "@azure-tools/typespec-ts"
options:
"@azure-tools/typespec-ts":
isModularLibrary: true
generateMetadata: true
is-modular-library: true
generate-metadata: true
branded: false
"emitter-output-dir": "{project-root}/../generated/typespec-ts"
packageDetails:
emitter-output-dir: "{project-root}/../generated/typespec-ts"
package-details:
name: "@msinternal/openai-non-branded"
Loading

0 comments on commit 26a7f7d

Please sign in to comment.