From d49c9471da311c5fb2ac5a65f9f27bef6649b5ac Mon Sep 17 00:00:00 2001 From: Anthony Martin <38542602+anthony-c-martin@users.noreply.github.com> Date: Mon, 9 Jun 2025 09:24:59 -0400 Subject: [PATCH 1/2] Remove temporary conversion script --- dev/deployments/convert/.tsconfig | 22 - dev/deployments/convert/main.ts | 365 ------------ dev/deployments/convert/markdown.ts | 671 ---------------------- dev/deployments/convert/package-lock.json | 216 ------- dev/deployments/convert/package.json | 18 - 5 files changed, 1292 deletions(-) delete mode 100644 dev/deployments/convert/.tsconfig delete mode 100644 dev/deployments/convert/main.ts delete mode 100644 dev/deployments/convert/markdown.ts delete mode 100644 dev/deployments/convert/package-lock.json delete mode 100644 dev/deployments/convert/package.json diff --git a/dev/deployments/convert/.tsconfig b/dev/deployments/convert/.tsconfig deleted file mode 100644 index 17bf5887e869..000000000000 --- a/dev/deployments/convert/.tsconfig +++ /dev/null @@ -1,22 +0,0 @@ -{ - "compilerOptions": { - "skipLibCheck": true, - "module": "commonjs", - "noEmitOnError": true, - "noImplicitReturns": true, - "sourceMap": true, - "declarationMap": true, - "strict": true, - "declaration": true, - "stripInternal": true, - "noEmitHelpers": false, - "target": "es2019", - "types": ["node"], - "esModuleInterop": true, - "lib": ["es2020"], - "newLine": "LF", - "outDir": "dist", - "rootDir": "." - }, - "exclude": ["dist", "node_modules"] -} \ No newline at end of file diff --git a/dev/deployments/convert/main.ts b/dev/deployments/convert/main.ts deleted file mode 100644 index 8cbdbdfc69d5..000000000000 --- a/dev/deployments/convert/main.ts +++ /dev/null @@ -1,365 +0,0 @@ -/* -To run: -git checkout origin/main -- specification/resources/resource-manager/Microsoft.Resources -npm --prefix dev/deployments/convert ci -npm --prefix dev/deployments/convert start -*/ - -import path, { basename, dirname } from 'path'; -import { mkdirSync, readFileSync, readdirSync, renameSync, unlinkSync, writeFileSync } from 'fs'; -import { spawnSync } from 'child_process'; -import { replaceSourceReadmes, writeMarkdownFiles } from './markdown'; - -const deploymentsPaths = [ - '/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}', - '/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel', - '/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/validate', - '/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate', - '/{scope}/providers/Microsoft.Resources/deployments/', - '/providers/Microsoft.Resources/deployments/{deploymentName}', - '/providers/Microsoft.Resources/deployments/{deploymentName}/cancel', - '/providers/Microsoft.Resources/deployments/{deploymentName}/validate', - '/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf', - '/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate', - '/providers/Microsoft.Resources/deployments/', - '/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}', - '/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel', - '/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/validate', - '/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf', - '/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate', - '/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/', - '/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}', - '/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel', - '/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/validate', - '/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf', - '/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate', - '/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/', - '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}', - '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/cancel', - '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/validate', - '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/whatIf', - '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/{deploymentName}/exportTemplate', - '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.Resources/deployments/', - '/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}', - '/{scope}/providers/Microsoft.Resources/deployments/{deploymentName}/operations', - '/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}', - '/providers/Microsoft.Resources/deployments/{deploymentName}/operations', - '/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}', - '/providers/Microsoft.Management/managementGroups/{groupId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations', - '/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations/{operationId}', - '/subscriptions/{subscriptionId}/providers/Microsoft.Resources/deployments/{deploymentName}/operations', - '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/deployments/{deploymentName}/operations/{operationId}', - '/subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/deployments/{deploymentName}/operations', - '/providers/Microsoft.Resources/calculateTemplateHash', -]; - -function getFiles(dir: string, fileName: string) { - const dirents = readdirSync(dir, { withFileTypes: true }); - let files: string[] = []; - for (const dirent of dirents) { - const res = path.resolve(dir, dirent.name); - if (dirent.isDirectory()) { - files = [...files, ...getFiles(res, fileName)]; - } else { - if (basename(res).toLowerCase() === fileName.toLowerCase()) { - files = [...files, res]; - } - } - } - - return files; -} - -function splitResourcesJson(resourcesPath: string) { - const contentsString = readFileSync(resourcesPath, { encoding: 'utf-8'}); - const existing = JSON.parse(contentsString); - const newDeployments = JSON.parse(contentsString); - const newResources = JSON.parse(contentsString); - - const paths = existing['paths']; - const deploymentRefs = new Set(); - const resourcesRefs = new Set(); - for (const path of Object.keys(paths)) { - const isDeploymentsOwned = deploymentsPaths.indexOf(path) > -1; - - if (isDeploymentsOwned) { - delete newResources['paths'][path]; - } else { - delete newDeployments['paths'][path]; - } - - for (const ref of obtainRefs(existing, paths[path])) { - if (isDeploymentsOwned) { - deploymentRefs.add(ref); - } else { - resourcesRefs.add(ref); - } - } - } - - for (const ref of deploymentRefs) { - if (!resourcesRefs.has(ref)) { - deleteRef(newResources, ref); - } - } - for (const ref of resourcesRefs) { - if (!deploymentRefs.has(ref)) { - deleteRef(newDeployments, ref); - } - } - - const parentPath = path.dirname(resourcesPath); - const specsBasePath = path.dirname(path.dirname(parentPath)); - - const deploymentsBasePath = path.resolve(specsBasePath, 'deployments'); - const newDeploymentsPath = path.resolve(deploymentsBasePath, path.relative(specsBasePath, parentPath), 'deployments.json'); - - writeFileSync(resourcesPath, JSON.stringify(newResources, null, 2) + '\n'); - - newDeployments['info']['title'] = 'DeploymentsClient'; - newDeployments['info']['description'] = 'Provides operations for working with deployments.'; - writeSpecAndExamples(newDeployments, resourcesPath, newDeploymentsPath); - - return newDeploymentsPath; -} - -function writeSpecAndExamples(spec: any, sourcePath: string, destPath: string) { - fixRelativePaths(spec); - - mkdirSync(path.dirname(destPath), { recursive: true }); - writeFileSync(destPath, JSON.stringify(spec, null, 2) + '\n'); - - for (const examplePath of obtainExamples(spec)) { - const exampleSourcePath = path.resolve(dirname(sourcePath), examplePath); - const exampleDestPath = path.resolve(dirname(destPath), examplePath); - - mkdirSync(path.dirname(exampleDestPath), { recursive: true }); - renameSync(exampleSourcePath, exampleDestPath); - } -} - -function deleteRef(document: any, ref: string) { - if (!ref.startsWith('#/')) { - throw `Cannot process ref ${ref}`; - } - - const path = ref.substring(2).split('/'); - let refLookup = document; - while (path.length > 1) { - const key = path.shift() as string; - refLookup = refLookup[key]; - } - - delete refLookup[path[0]]; -} - -function obtainRefs(document: any, node: any): string[] { - const refs = new Set(); - const nodes = [node]; - - while (nodes.length > 0) { - const curNode = nodes.pop(); - const curRefs = findRefsRecursive(curNode); - for (const curRef of curRefs) { - if (refs.has(curRef)) { - continue; - } - - refs.add(curRef); - if (curRef.startsWith('#/')) { - const path = curRef.substring(2).split('/'); - let refLookup = document; - while (path.length > 0) { - const key = path.shift() as string; - refLookup = refLookup[key]; - } - - if (!refLookup) { - throw `Failed to find definition ${curRef}`; - } - - nodes.push(refLookup); - } - } - } - - return [...refs].filter(x => x.startsWith('#/')); -} - -function* obtainExamples(document: any) { - for (const exampleBlock of findExamplesRecursive(document)) { - for (const example of Object.values(exampleBlock)) { - if (typeof example['$ref'] === 'string') { - yield example['$ref']; - } - } - } -} - -function* findRefsRecursive(node: any): Generator { - if (typeof node === 'object') { - if (typeof node['$ref'] === 'string') { - yield node['$ref']; - } - if (typeof node['x-ms-odata'] === 'string') { - yield node['x-ms-odata']; - } - - for (const key of Object.keys(node)) { - yield* findRefsRecursive(node[key]); - } - } else if (Array.isArray(node)) { - for (const item of node) { - yield* findRefsRecursive(item); - } - } -} - -function* findExamplesRecursive(node: any): Generator> { - if (typeof node === 'object') { - if (typeof node['x-ms-examples'] === 'object') { - yield node['x-ms-examples']; - } - - for (const key of Object.keys(node)) { - yield* findExamplesRecursive(node[key]); - } - } else if (Array.isArray(node)) { - for (const item of node) { - yield* findExamplesRecursive(item); - } - } -} - -function fixRelativePaths(node: any) { - if (typeof node === 'object') { - if (typeof node['$ref'] === 'string' && - node['$ref'].startsWith('../../../../../common-types/')) { - // new files are emitted one dir level deeper, we need to adjust for that - node['$ref'] = `../${node['$ref']}`; - } - - for (const key of Object.keys(node)) { - fixRelativePaths(node[key]); - } - } else if (Array.isArray(node)) { - for (const item of node) { - fixRelativePaths(item); - } - } -} - -function moveJsonSpec(specPath: string, newPathName: string) { - const contentsString = readFileSync(specPath, { encoding: 'utf-8'}); - const existing = JSON.parse(contentsString); - - const parentPath = path.dirname(specPath); - const specsBasePath = path.dirname(path.dirname(parentPath)); - - const deploymentsBasePath = path.resolve(specsBasePath, newPathName); - const newSpecPath = path.resolve(deploymentsBasePath, path.relative(specsBasePath, parentPath), basename(specPath)); - - writeSpecAndExamples(existing, specPath, newSpecPath); - unlinkSync(specPath); - - return newSpecPath; -} - -function generateDeploymentsFiles(basePath: string) { - const filePaths = getFiles(basePath, 'resources.json'); - const newFilePaths = filePaths.map(p => p.replace('resources.json', 'deployments.json')); - - let newPaths = []; - for (const filePath of filePaths) { - newPaths.push(splitResourcesJson(filePath)); - } - writeMarkdownFiles(path.resolve(basePath, 'deployments'), newFilePaths.map(x => path.relative(basePath, x)), 'Deployments', 'DeploymentsClient'); - - return newPaths; -} - -function generateDeploymentScriptsFiles(basePath: string) { - const filePaths = getFiles(basePath, 'deploymentScripts.json'); - - let newPaths = []; - for (const filePath of filePaths) { - newPaths.push(moveJsonSpec(filePath, 'deploymentScripts')); - } - writeMarkdownFiles(path.resolve(basePath, 'deploymentScripts'), filePaths.map(x => path.relative(basePath, x)), 'DeploymentScripts', 'DeploymentScriptsClient'); - - return newPaths; -} - -function generateDeploymentStacksFiles(basePath: string) { - const filePaths = getFiles(basePath, 'deploymentStacks.json'); - - let newPaths = []; - for (const filePath of filePaths) { - newPaths.push(moveJsonSpec(filePath, 'deploymentStacks')); - } - writeMarkdownFiles(path.resolve(basePath, 'deploymentStacks'), filePaths.map(x => path.relative(basePath, x)), 'DeploymentStacks', 'DeploymentStacksClient'); - - return newPaths; -} - -function generateTemplateSpecsFiles(basePath: string) { - const filePaths = getFiles(basePath, 'templateSpecs.json'); - - let newPaths = []; - for (const filePath of filePaths) { - newPaths.push(moveJsonSpec(filePath, 'templateSpecs')); - } - writeMarkdownFiles(path.resolve(basePath, 'templateSpecs'), filePaths.map(x => path.relative(basePath, x)), 'TemplateSpecs', 'TemplateSpecsClient'); - - return newPaths; -} - -function generateBicepFiles(basePath: string) { - const filePaths = getFiles(basePath, 'bicepClient.json'); - - let newPaths = []; - for (const filePath of filePaths) { - newPaths.push(moveJsonSpec(filePath, 'bicep')); - } - writeMarkdownFiles(path.resolve(basePath, 'bicep'), filePaths.map(x => path.relative(basePath, x)), 'Bicep', 'BicepClient'); - - return newPaths; -} - -function writeSuppressions(basePath: string, apiFilesByService: Record) { - let contents = ''; - - for (const [_, filePaths] of Object.entries(apiFilesByService)) { - const relativePaths = filePaths.map(x => path.relative(basePath, x)); - contents += ` -- tool: TypeSpecRequirement - paths: - - ${relativePaths.join('\n - ')} - reason: Brownfield service not ready to migrate -`; - } - - writeFileSync(path.resolve(basePath, 'suppressions.yaml'), contents); -} - -function main() { - // change this if wanting to base off a later commit # - const baseCommit = 'fc1f625dbec2d92ba4d9dd0df16ece543b04fec9'; - const serviceBasePath = path.resolve(__dirname, '../../../specification/resources'); - const rpBasePath = path.resolve(serviceBasePath, 'resource-manager/Microsoft.Resources'); - - spawnSync('git', ['restore', `--source=${baseCommit}`, '--worktree', '--', serviceBasePath]); - - let apiFilesByService: Record = {}; - apiFilesByService['deployments'] = generateDeploymentsFiles(rpBasePath); - apiFilesByService['templateSpecs'] = generateTemplateSpecsFiles(rpBasePath); - apiFilesByService['deploymentStacks'] = generateDeploymentStacksFiles(rpBasePath); - apiFilesByService['deploymentScripts'] = generateDeploymentScriptsFiles(rpBasePath); - apiFilesByService['bicep'] = generateBicepFiles(rpBasePath); - - writeSuppressions(rpBasePath, apiFilesByService); - - replaceSourceReadmes(rpBasePath); -} - -main(); \ No newline at end of file diff --git a/dev/deployments/convert/markdown.ts b/dev/deployments/convert/markdown.ts deleted file mode 100644 index 51c3abe2774c..000000000000 --- a/dev/deployments/convert/markdown.ts +++ /dev/null @@ -1,671 +0,0 @@ -import path from "path"; -import { readFileSync, writeFileSync } from "fs"; - -type Component = 'Deployments' | 'DeploymentScripts' | 'DeploymentStacks' | 'TemplateSpecs' | 'Bicep'; - -export function writeMarkdownFiles(basePath: string, filePaths: string[], componentName: Component, clientName: string) { - const apiVersions = filePaths.map((filePath) => getApiVersionFromFilePath(filePath)); - apiVersions.sort((a, b) => b.localeCompare(a)); - const latestApiVersion = apiVersions[0]; - - writeReadme(basePath, 'readme.md', getMainReadme(clientName, componentName, filePaths, latestApiVersion, suppressions[componentName]).trimStart()); - writeReadme(basePath, 'readme.csharp.md', getCsharpReadme(componentName).trimStart()); - writeReadme(basePath, 'readme.go.md', getGoReadme(componentName).trimStart()); - writeReadme(basePath, 'readme.java.md', getJavaReadme(componentName).trimStart()); - writeReadme(basePath, 'readme.python.md', getPythonReadme(componentName).trimStart()); - writeReadme(basePath, 'readme.typescript.md', getTypescriptReadme(clientName, componentName).trimStart()); -} - -function writeReadme(basePath: string, fileName: string, readme: string) { - // Remove leading + trailing whitespace, add a final newline - readme = readme.trim() + '\n'; - - writeFileSync(path.resolve(basePath, fileName), readme); -} - -function replaceMarkdownSectionMatching(readme: string, matcher: (heading: string) => boolean, replacer: (body: string) => string) { - return readme.replace(/(##.*?\n)([\s\S]*?)(?=\n##|$)/g, (match, _) => { - return matcher(match.split('\n')[0]) ? replacer(match) : match; - }); -} - -function removeMarkdownSectionMatching(readme: string, matcher: (heading: string) => boolean) { - return replaceMarkdownSectionMatching(readme, matcher, (_) => ''); -} - -function replaceCodeblockMatching(readme: string, matcher: (heading: string) => boolean, replacer: (body: string) => string) { - return readme.replace(/(```.*?\n)([\s\S]*?)(\n```\n\n)/g, (match, _) => { - return matcher(match.split('\n')[0]) ? replacer(match) : match; - }); -} - -function removeCodeblockMatching(readme: string, matcher: (heading: string) => boolean) { - return replaceCodeblockMatching(readme, matcher, (_) => ''); -} - -function removeLinesMatching(readme: string, matcher: (line: string) => boolean) { - return readme.split('\n').filter(x => !matcher(x)).join('\n'); -} - -function removeSuppressionMatching(readme: string, matcher: (body: string) => boolean) { - return readme.replace(/([ ]*- (from|suppress): .*?\n)([\s\S]*?)(?=\n[ ]*- (from|suppress): |```)\n/g, (match, _) => { - if (matcher(match)) { - return ''; - } - - return match; - }); -} - -function replaceFile(filePath: string, updateFunc: (content: string) => string) { - const content = readFileSync(filePath, 'utf8'); - const updatedContent = updateFunc(content); - writeFileSync(filePath, updatedContent); -} - -export function replaceSourceReadmes(basePath: string) { - const packagePattern = /(deploymentscripts|templatespecs|deploymentstacks|bicep)/; - - const readmes = [ - 'readme.md', - 'readme.go.md', - 'readme.java.md', - 'readme.nodejs.md', - 'readme.python.md', - 'readme.ruby.md', - 'readme.terraform.md', - 'readme.typescript.md', - ]; - - for (const readme of readmes) { - replaceFile(path.resolve(basePath, `../${readme}`), (content) => { - content = removeMarkdownSectionMatching(content, (heading) => packagePattern.test(heading)); - content = removeCodeblockMatching(content, heading => packagePattern.test(heading)); - - if (readme === 'readme.md') { - const movedFilesPattern = /from: (deploymentScripts|templateSpecs|deploymentStacks|bicep)/; - content = removeSuppressionMatching(content, body => movedFilesPattern.test(body)); - - content = replaceMarkdownSectionMatching( - content, - (heading) => heading === '## Suppression', - (sup) => replaceCodeblockMatching(sup, (_) => true, (cb) => { - return cb.trimEnd().replace(`\n\`\`\``, ` - - suppress: OperationsAPIImplementation - from: Microsoft.Resources/stable/2016-02-01/resources.json - reason: Pre-existing lint error. - - suppress: OperationsAPIImplementation - from: Microsoft.Resources/stable/2016-07-01/resources.json - reason: Pre-existing lint error. - - suppress: OperationsAPIImplementation - from: Microsoft.Resources/stable/2016-09-01/resources.json - reason: Pre-existing lint error. - - suppress: OperationsAPIImplementation - from: Microsoft.Resources/stable/2017-05-10/resources.json - reason: Pre-existing lint error. - - suppress: OperationsAPIImplementation - from: Microsoft.Resources/stable/2018-02-01/resources.json - reason: Pre-existing lint error. -\`\`\` - -`); - })); - } - - content = removeLinesMatching(content, line => packagePattern.test(line)); - - return content; - }); - } -} - -function getPackageName(apiVersion: string) { - const year = apiVersion.split('-')[0]; - const month = apiVersion.split('-')[1]; - const suffix = apiVersion.split('-')[2] === '01' ? '' : `${apiVersion.split('-')[2]}`; - - return `package-${year}-${month}${suffix}`; -} - -function getApiVersionFromFilePath(filePath: string) { - return filePath.replace(/^\.\//, '').split('/')[1]; -} - -function getMainReadme(clientName: string, componentName: string, filePaths: string[], latestApiVersion: string, suppressions: string | undefined) { - let readme = ` -# ${componentName} - -> see https://aka.ms/autorest - -This is the AutoRest configuration file for ${componentName}. - -## Getting Started - -To build the SDKs for ${componentName}, simply install AutoRest via \`npm\` (\`npm install -g autorest\`) and then run: - -> \`autorest readme.md\` - -To see additional help and options, run: - -> \`autorest --help\` - -For other options on installation see [Installing AutoRest](https://aka.ms/autorest/install) on the AutoRest github page. - ---- - -## Configuration - -### Basic Information - -These are the global settings for the ${componentName} client. - -\`\`\` yaml -title: ${clientName} -description: ${componentName} Client -openapi-type: arm -tag: ${getPackageName(latestApiVersion)} -\`\`\` - ---- -`; - - for (const filePath of filePaths) { - const apiVersion = getApiVersionFromFilePath(filePath); - const packageName = getPackageName(apiVersion); - readme += ` -### Tag: ${packageName} - -These settings apply only when \`--tag=${packageName}\` is specified on the command line. - -\`\`\` yaml $(tag) == '${packageName}' -input-file: - - ${filePath} -\`\`\` -`; - } - - if (suppressions) { - readme += ` -## Suppression - -\`\`\` yaml -${suppressions.trim()} -\`\`\` -`; - } - - readme += ` -# Code Generation - -## Swagger to SDK - -This section describes what SDK should be generated by the automatic system. -This is not used by Autorest itself. - -\`\`\` yaml $(swagger-to-sdk) -swagger-to-sdk: - - repo: azure-sdk-for-net - - repo: azure-sdk-for-python - - repo: azure-sdk-for-java - - repo: azure-sdk-for-go - - repo: azure-sdk-for-js - - repo: azure-powershell -\`\`\` - -## CSharp - -See configuration in [readme.csharp.md](./readme.csharp.md) - -## Go - -See configuration in [readme.go.md](./readme.go.md) - -## Java - -See configuration in [readme.java.md](./readme.java.md) - -## Python - -See configuration in [readme.python.md](./readme.python.md) - -## TypeScript - -See configuration in [readme.typescript.md](./readme.typescript.md) -`; - return readme; -} - -function getCsharpReadme(componentName: string) { - return ` -## C# - -These settings apply only when \`--csharp\` is specified on the command line. -Please also specify \`--csharp-sdks-folder=\`. - -\`\`\`yaml $(csharp) -csharp: - azure-arm: true - license-header: MICROSOFT_MIT_NO_VERSION - payload-flattening-threshold: 1 - clear-output-folder: true - client-side-validation: false - namespace: Azure.ResourceManager.Resources.${componentName} - output-folder: $(csharp-sdks-folder)/resources/Azure.ResourceManager.Resources.${componentName}/GeneratedProtocol -\`\`\` -`; -} - -function getGoReadme(componentName: string) { - return ` -## Go - -These settings apply only when \`--go\` is specified on the command line. - - -\`\`\` yaml $(go) && $(track2) -license-header: MICROSOFT_MIT_NO_VERSION -module-name: sdk/resourcemanager/resources/arm${componentName.toLowerCase()} -module: github.com/Azure/azure-sdk-for-go/$(module-name) -output-folder: $(go-sdk-folder)/$(module-name) -azure-arm: true -\`\`\` -`; -} - -function getJavaReadme(componentName: string) { - return ` -## Java - -These settings apply only when \`--java\` is specified on the command line. -Please also specify \`--azure-libraries-for-java-folder=\`. - -\`\`\` yaml $(java) -java: - azure-arm: true - fluent: true - namespace: com.microsoft.azure.management.resources.${componentName.toLowerCase()} - output-folder: $(azure-libraries-for-java-folder)/sdk/resources/${componentName.toLowerCase()} - license-header: MICROSOFT_MIT_NO_CODEGEN - payload-flattening-threshold: 1 -\`\`\` -`; -} - -function getPythonReadme(componentName: string) { - return ` -## Python - -These settings apply only when \`--python\` is specified on the command line. -Please also specify \`--python-sdks-folder=\`. - -\`\`\` yaml $(python) -azure-arm: true -license-header: MICROSOFT_MIT_NO_VERSION -package-name: azure-mgmt-resources-${componentName.toLowerCase()} -namespace: azure.mgmt.resources.${componentName.toLowerCase()} -package-version: 1.0.0 -clear-output-folder: true -\`\`\` - -\`\`\` yaml $(python) -no-namespace-folders: true -output-folder: $(python-sdks-folder)/resources/azure-mgmt-resources-${componentName.toLowerCase()}/azure/mgmt/resources/${componentName.toLowerCase()} -\`\`\` -`; -} - -function getTypescriptReadme(clientName: string, componentName: string) { - return ` -## TypeScript - -These settings apply only when \`--typescript\` is specified on the command line. -Please also specify \`--typescript-sdks-folder=\`. - -\`\`\`yaml $(typescript) -typescript: - azure-arm: true - package-name: "@azure/arm-resources${componentName.toLowerCase()}" - output-folder: "$(typescript-sdks-folder)/sdk/resources/arm-resources${componentName.toLowerCase()}" - override-client-name: ${clientName} - generate-metadata: true -\`\`\` -`; -} - -type Suppression = { - suppress: string; - where?: string; - reason?: string; -}; - -const operationsApiSuppression: Suppression = { - suppress: 'OperationsAPIImplementation', - reason: 'Operations API is implemented as a separate service.', -}; - -const newSuppressions: Record = { - Deployments: [ - operationsApiSuppression, - { suppress: 'ProvisioningStateMustBeReadOnly' }, - { suppress: 'RequiredDefaultResponse' }, - { suppress: 'RequiredPropertiesMissingInResourceModel' }, - { suppress: 'RequestSchemaForTrackedResourcesMustHaveTags' }, - { suppress: 'DescriptionMustNotBeNodeName' }, - ], - DeploymentScripts: [ - operationsApiSuppression, - { suppress: 'XmsPageableForListCalls' }, - { suppress: 'AvoidAdditionalProperties' }, - { suppress: 'MissingTypeObject' }, - ], - DeploymentStacks: [ - operationsApiSuppression, - { suppress: 'DefaultErrorResponseSchema' }, - ], - TemplateSpecs: [ - operationsApiSuppression, - { suppress: 'AvoidAdditionalProperties' }, - { suppress: 'MissingTypeObject' }, - { suppress: 'ParametersInPointGet' }, - { suppress: 'PathForTrackedResourceTypes' }, - ], - Bicep: [ - operationsApiSuppression, - ], -}; - -function getNewSuppressions(component: Component) { - let output = ''; - for (const suppression of newSuppressions[component]) { - const { suppress, where, reason } = suppression; - const reasonText = reason ?? 'Pre-existing lint error.'; - output += ` - suppress: ${suppress} - from: ${filePathLookup[component]} - reason: ${reasonText} -`; - if (where) { - output += ` where: ${where} -`; - } - } - - return output; -} - -const filePathLookup: Record = { - Deployments: 'deployments.json', - DeploymentScripts: 'deploymentScripts.json', - DeploymentStacks: 'deploymentStacks.json', - TemplateSpecs: 'templateSpecs.json', - Bicep: 'bicepClient.json', -}; - -const suppressions: Record = { - Deployments: ` -directive: - - suppress: UniqueResourcePaths - from: deployments.json - where: $.paths - reason: route definitions under an extension resource with Microsoft.Management - - suppress: DescriptionAndTitleMissing - where: $.definitions.AliasPathMetadata - from: deployments.json - reason: This was already checked in - not my code - - suppress: XMS_EXAMPLE_NOTFOUND_ERROR - where: $.paths - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: OperationsApiResponseSchema - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: OperationsApiSchemaUsesCommonTypes - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: NoDuplicatePathsForScopeParameter - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: LroLocationHeader - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: LroErrorContent - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: NoErrorCodeResponses - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PutRequestResponseSchemeArm - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PutResponseSchemaDescription - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PostOperationAsyncResponseValidation - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: MissingXmsErrorResponse - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PathForPutOperation - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PathResourceProviderMatchNamespace - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: ParametersOrder - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: SyncPostReturn - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PathContainsResourceType - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: OperationIdNounVerb - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PathForResourceAction - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: UnSupportedPatchProperties - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: LroPostReturn - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: ProvisioningStateSpecifiedForLROPut - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: ProvisioningStateSpecifiedForLROPatch - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: SubscriptionsAndResourceGroupCasing - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: ResourceNameRestriction - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: ConsistentPatchProperties - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: GetCollectionOnlyHasValueAndNextLink - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: MissingTypeObject - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: TrackedResourcePatchOperation - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: IntegerTypeMustHaveFormat - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: BodyTopLevelProperties - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: TopLevelResourcesListBySubscription - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: XmsParameterLocation - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PathForTrackedResourceTypes - from: deployments.json - reason: Not a tracked resource type. Cannot change anything due to design philosophy in ARM. - - suppress: PostResponseCodes - from: deployments.json - reason: Breaking change in order to change the API response code. - - suppress: TenantLevelAPIsNotAllowed - from: deployments.json - reason: Tenant level API's are allowed as an exception in ARM repo. It is a breaking change to modify it. - - suppress: XmsPageableForListCalls - from: deployments.json - reason: Shared swagger with other teams. We cannot make changes to the API as we don't own it. - - suppress: EvenSegmentedPathForPutOperation - from: deployments.json - reason: Linter rule limitation. The API has never been changed since inception. Would be a breaking change. - - suppress: DeleteResponseCodes - from: deployments.json - reason: Breaking change in order to change the API response code. - - suppress: PutResponseCodes - from: deployments.json - reason: Breaking change in order to change the API response code. - - suppress: AvoidAdditionalProperties - from: deployments.json - reason: Breaking change in order to change the property names for multiple API's. Will fix in the future. - - suppress: XmsExamplesRequired - from: deployments.json - reason: Xms Examples required is a pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: RequiredReadOnlySystemData - from: deployments.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future - - suppress: TrackedExtensionResourcesAreNotAllowed - from: deployments.json - reason: "The deployments resource type is ProxyOnly." - - suppress: RequiredPropertiesMissingInResourceModel - from: deployments.json - where: $.definitions.Provider - reason: "Historically some properties have not been returned for this model and reviewer said OK to suppress." - - suppress: RequiredPropertiesMissingInResourceModel - from: deployments.json - where: $.definitions.DeploymentOperation - reason: "Historically some properties have not been returned for this model and reviewer said OK to suppress." - - suppress: RequiredPropertiesMissingInResourceModel - from: deployments.json - where: $.definitions.DeploymentOperationsListResult - reason: "Historically some properties have not been returned for this model and reviewer said OK to suppress." -${getNewSuppressions('Deployments')} -`, - DeploymentScripts: ` -directive: - - from: deploymentScripts.json - suppress: TrackedResourceGetOperation - where: $.definitions.AzureCliScript - reason: Tooling issue. - - from: deploymentScripts.json - suppress: TrackedResourcePatchOperation - where: $.definitions.AzureCliScript - reason: Tooling issue. - - from: deploymentScripts.json - suppress: TrackedResourceGetOperation - where: $.definitions.AzurePowerShellScript - reason: Tooling issue - - from: deploymentScripts.json - suppress: TrackedResourcePatchOperation - where: $.definitions.AzurePowerShellScript - reason: Tooling issue - - suppress: IntegerTypeMustHaveFormat - from: deploymentScripts.json - reason: Tooling issue, default is int32, explicitly mentioning the format as per doc, it still flags breaking change. - - suppress: ResourceNameRestriction - from: deploymentScripts.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PropertiesTypeObjectNoDefinition - from: deploymentScripts.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: SubscriptionsAndResourceGroupCasing - from: deploymentScripts.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: ParametersInPointGet - from: deploymentScripts.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: GetCollectionOnlyHasValueAndNextLink - from: deploymentScripts.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: PatchIdentityProperty - from: deploymentScripts.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: LroErrorContent - from: deploymentScripts.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - suppress: ProvisioningStateSpecifiedForLROPut - from: deploymentScripts.json - reason: Pre-existing lint error. Not related to this version release. Will fix in the future. - - from: deploymentScripts.json - suppress: R3006 - where: - - $.definitions.DeploymentScript.properties - - $.definitions.AzureCliScript.properties - - $.definitions.AzurePowerShellScript.properties - reason: Currently systemData is not allowed -${getNewSuppressions('DeploymentScripts')} -`, - DeploymentStacks: ` -directive: - - from: deploymentStacks.json - suppress: TrackedResourcePatchOperation - where: $.definitions - reason: Not a tracked resource. - - suppress: PathForTrackedResourceTypes - from: deploymentStacks.json - reason: "A deployment stack resource is a proxy location-mapped resource type." - - suppress: TenantLevelAPIsNotAllowed - from: deploymentStacks.json - reason: "Working with deployment stacks at the management group scope is supported." - - suppress: TrackedResourcePatchOperation - from: deploymentStacks.json - reason: "A deployment stack resource is a proxy location-mapped resource type." - - suppress: AvoidAdditionalProperties - from: deploymentStacks.json - reason: "Deployment properties such as 'parameters', 'outputs', and 'template' are dynamic types. For example, properties of the parameters object are defined by the template content." - - suppress: PostResponseCodes - from: deploymentStacks.json - reason: "Validate endpoints have 200, 202, 400, and default responses. The 400 response inherits the error response." - - suppress: LroErrorContent - from: deploymentStacks.json - reason: Error response is inherited via allOf on flagged response. - - suppress: NoErrorCodeResponses - from: deploymentStacks.json - reason: A 400 response from the validate endpoint indicates a validation failure and should not throw an exception. - - suppress: MissingXmsErrorResponse - from: deploymentStacks.json - reason: A 400 response from the validate endpoint indicates a validation failure and should not throw an exception. - - suppress: DeleteResponseCodes - from: deploymentStacks.json - reason: Deployment stacks supports synchronous delete with 200 response. -${getNewSuppressions('DeploymentStacks')} -`, - TemplateSpecs: ` -directive: - - suppress: R3006 - from: templateSpecs.json - where: - - $.definitions.TemplateSpec.properties - - $.definitions.TemplateSpecVersion.properties - - $.definitions.TemplateSpecUpdateModel.properties - - $.definitions.TemplateSpecVersionUpdateModel.properties - reason: Currently systemData is not allowed - - suppress: TrackedResourceListByImmediateParent - from: templateSpecs.json - where: $.definitions - reason: Tooling issue - - suppress: TrackedResourceListByResourceGroup - from: templateSpecs.json - where: $.definitions.TemplateSpecVersion - reason: Tooling issue -${getNewSuppressions('TemplateSpecs')} -`, - Bicep: ` -directive: -${getNewSuppressions('Bicep')} -`, -} \ No newline at end of file diff --git a/dev/deployments/convert/package-lock.json b/dev/deployments/convert/package-lock.json deleted file mode 100644 index 857a4d3a9b19..000000000000 --- a/dev/deployments/convert/package-lock.json +++ /dev/null @@ -1,216 +0,0 @@ -{ - "name": "convert", - "version": "1.0.0", - "lockfileVersion": 3, - "requires": true, - "packages": { - "": { - "name": "convert", - "version": "1.0.0", - "license": "MIT", - "devDependencies": { - "@types/node": "^20.11.20", - "ts-node": "^10.9.2" - }, - "engines": { - "node": "20.x" - } - }, - "node_modules/@cspotcode/source-map-support": { - "version": "0.8.1", - "resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz", - "integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==", - "dev": true, - "dependencies": { - "@jridgewell/trace-mapping": "0.3.9" - }, - "engines": { - "node": ">=12" - } - }, - "node_modules/@jridgewell/resolve-uri": { - "version": "3.1.2", - "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.2.tgz", - "integrity": "sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==", - "dev": true, - "engines": { - "node": ">=6.0.0" - } - }, - "node_modules/@jridgewell/sourcemap-codec": { - "version": "1.4.15", - "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.15.tgz", - "integrity": "sha512-eF2rxCRulEKXHTRiDrDy6erMYWqNw4LPdQ8UQA4huuxaQsVeRPFl2oM8oDGxMFhJUWZf9McpLtJasDDZb/Bpeg==", - "dev": true - }, - "node_modules/@jridgewell/trace-mapping": { - "version": "0.3.9", - "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", - "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", - "dev": true, - "dependencies": { - "@jridgewell/resolve-uri": "^3.0.3", - "@jridgewell/sourcemap-codec": "^1.4.10" - } - }, - "node_modules/@tsconfig/node10": { - "version": "1.0.9", - "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", - "integrity": "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==", - "dev": true - }, - "node_modules/@tsconfig/node12": { - "version": "1.0.11", - "resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz", - "integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==", - "dev": true - }, - "node_modules/@tsconfig/node14": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz", - "integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==", - "dev": true - }, - "node_modules/@tsconfig/node16": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.4.tgz", - "integrity": "sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA==", - "dev": true - }, - "node_modules/@types/node": { - "version": "20.11.20", - "resolved": "https://registry.npmjs.org/@types/node/-/node-20.11.20.tgz", - "integrity": "sha512-7/rR21OS+fq8IyHTgtLkDK949uzsa6n8BkziAKtPVpugIkO6D+/ooXMvzXxDnZrmtXVfjb1bKQafYpb8s89LOg==", - "dev": true, - "dependencies": { - "undici-types": "~5.26.4" - } - }, - "node_modules/acorn": { - "version": "8.11.3", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.11.3.tgz", - "integrity": "sha512-Y9rRfJG5jcKOE0CLisYbojUjIrIEE7AGMzA/Sm4BslANhbS+cDMpgBdcPT91oJ7OuJ9hYJBx59RjbhxVnrF8Xg==", - "dev": true, - "bin": { - "acorn": "bin/acorn" - }, - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/acorn-walk": { - "version": "8.3.2", - "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.3.2.tgz", - "integrity": "sha512-cjkyv4OtNCIeqhHrfS81QWXoCBPExR/J62oyEqepVw8WaQeSqpW2uhuLPh1m9eWhDuOo/jUXVTlifvesOWp/4A==", - "dev": true, - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/arg": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", - "dev": true - }, - "node_modules/create-require": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", - "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", - "dev": true - }, - "node_modules/diff": { - "version": "4.0.2", - "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", - "dev": true, - "engines": { - "node": ">=0.3.1" - } - }, - "node_modules/make-error": { - "version": "1.3.6", - "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", - "dev": true - }, - "node_modules/ts-node": { - "version": "10.9.2", - "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.2.tgz", - "integrity": "sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ==", - "dev": true, - "dependencies": { - "@cspotcode/source-map-support": "^0.8.0", - "@tsconfig/node10": "^1.0.7", - "@tsconfig/node12": "^1.0.7", - "@tsconfig/node14": "^1.0.0", - "@tsconfig/node16": "^1.0.2", - "acorn": "^8.4.1", - "acorn-walk": "^8.1.1", - "arg": "^4.1.0", - "create-require": "^1.1.0", - "diff": "^4.0.1", - "make-error": "^1.1.1", - "v8-compile-cache-lib": "^3.0.1", - "yn": "3.1.1" - }, - "bin": { - "ts-node": "dist/bin.js", - "ts-node-cwd": "dist/bin-cwd.js", - "ts-node-esm": "dist/bin-esm.js", - "ts-node-script": "dist/bin-script.js", - "ts-node-transpile-only": "dist/bin-transpile.js", - "ts-script": "dist/bin-script-deprecated.js" - }, - "peerDependencies": { - "@swc/core": ">=1.2.50", - "@swc/wasm": ">=1.2.50", - "@types/node": "*", - "typescript": ">=2.7" - }, - "peerDependenciesMeta": { - "@swc/core": { - "optional": true - }, - "@swc/wasm": { - "optional": true - } - } - }, - "node_modules/typescript": { - "version": "5.3.3", - "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.3.3.tgz", - "integrity": "sha512-pXWcraxM0uxAS+tN0AG/BF2TyqmHO014Z070UsJ+pFvYuRSq8KH8DmWpnbXe0pEPDHXZV3FcAbJkijJ5oNEnWw==", - "dev": true, - "peer": true, - "bin": { - "tsc": "bin/tsc", - "tsserver": "bin/tsserver" - }, - "engines": { - "node": ">=14.17" - } - }, - "node_modules/undici-types": { - "version": "5.26.5", - "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz", - "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==", - "dev": true - }, - "node_modules/v8-compile-cache-lib": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz", - "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==", - "dev": true - }, - "node_modules/yn": { - "version": "3.1.1", - "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", - "dev": true, - "engines": { - "node": ">=6" - } - } - } -} diff --git a/dev/deployments/convert/package.json b/dev/deployments/convert/package.json deleted file mode 100644 index ee8a228edbbb..000000000000 --- a/dev/deployments/convert/package.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "name": "convert", - "version": "1.0.0", - "description": "", - "main": "index.js", - "scripts": { - "start": "ts-node --project .tsconfig main.ts" - }, - "author": "", - "license": "MIT", - "devDependencies": { - "@types/node": "^20.11.20", - "ts-node": "^10.9.2" - }, - "engines": { - "node": "20.x" - } -} From 5894347f16a102eb571cd2155786ec5e3f4382a7 Mon Sep 17 00:00:00 2001 From: Anthony Martin <38542602+anthony-c-martin@users.noreply.github.com> Date: Wed, 11 Jun 2025 21:13:13 -0400 Subject: [PATCH 2/2] Update launch.json --- .vscode/launch.json | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/.vscode/launch.json b/.vscode/launch.json index 1968170cd206..8815f85ff2fd 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -4,16 +4,6 @@ // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 "version": "0.2.0", "configurations": [ - { - "name": "Split Deployments", - "type": "node", - "request": "launch", - "runtimeExecutable": "npm", - "args": [ - "start" - ], - "cwd": "${workspaceFolder}/dev/deployments/convert" - }, { "type": "node", "request": "launch", @@ -34,4 +24,4 @@ "program": "${file}" } ] -} \ No newline at end of file +}