Skip to content

Commit

Permalink
Lint TS code
Browse files Browse the repository at this point in the history
  • Loading branch information
swallez committed Oct 23, 2023
1 parent 0b24a09 commit 11d15f3
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions compiler/src/transform/schema-to-openapi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,23 +17,23 @@
* under the License.
*/

import {convert_schema_to_openapi} from 'schema-wasm-lib';
import {argv} from "zx";
import {join} from "path";
import {readFileSync, writeFileSync} from "fs";
import { convert_schema_to_openapi } from 'schema-wasm-lib'
import { argv } from 'zx'
import { join } from 'path'
import { readFileSync, writeFileSync } from 'fs'

const inputPath = argv.input ?? join(__dirname, '..', '..', '..', 'output', 'schema', 'schema.json')
const outputPath = argv.output ?? join(__dirname, '..', '..', '..', 'output', 'openapi', 'elasticsearch-serverless-openapi.json')

const inputText = readFileSync(
inputPath,
{ encoding: 'utf8' }
);
inputPath,
{ encoding: 'utf8' }
)

const output = convert_schema_to_openapi(inputText, "serverless");
const output = convert_schema_to_openapi(inputText, 'serverless')

writeFileSync(
outputPath,
output,
'utf8'
outputPath,
output,
'utf8'
)

0 comments on commit 11d15f3

Please sign in to comment.