mirror of
https://github.com/saltbo/zpan.git
synced 2026-08-31 02:04:40 +08:00
8 lines
361 B
TypeScript
8 lines
361 B
TypeScript
import { mkdir, writeFile } from 'node:fs/promises'
|
|
import { dirname, resolve } from 'node:path'
|
|
import { downloaderOpenAPIDocument } from '../server/openapi/downloader'
|
|
|
|
const output = resolve('docs/openapi/downloader.json')
|
|
await mkdir(dirname(output), { recursive: true })
|
|
await writeFile(output, `${JSON.stringify(downloaderOpenAPIDocument(), null, 2)}\n`)
|