Skip to content

Commit 485ef2a

Browse files
committed
chore: Simplify dump-schema script to a bare minimum
1 parent 1b35614 commit 485ef2a

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

packages/openneuro-server/scripts/dump-schema.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,8 @@
22
* Dump the Pothos GraphQL schema to SDL.
33
*/
44
import { writeFileSync } from "fs"
5-
import { dirname, join } from "path"
6-
import { fileURLToPath } from "url"
75
import { lexicographicSortSchema, printSchema } from "graphql/index.js"
86
import schema from "../src/graphql/schema"
97

10-
console.log("Dumping GraphQL schema to SDL...")
118
const sdl = printSchema(lexicographicSortSchema(schema))
12-
const dir = dirname(fileURLToPath(import.meta.url))
13-
writeFileSync(join(dir, "..", "schema.graphql"), sdl + "\n")
9+
writeFileSync("schema.graphql", sdl + "\n")

0 commit comments

Comments
 (0)