mirror of
https://github.com/Effect-TS/effect.git
synced 2026-11-16 04:23:36 +08:00
Co-authored-by: Maxwell Brown <maxwellbrown1990@gmail.com>
20 lines
532 B
JavaScript
20 lines
532 B
JavaScript
// @ts-check
|
|
import * as Glob from "glob"
|
|
import Jscodeshift from "jscodeshift/src/Runner.js"
|
|
import * as Path from "node:path"
|
|
|
|
// Look up files in all workspace packages including those nested in
|
|
// sub-packages (e.g. `packages/ai/openapi`).
|
|
const pattern = "packages/{*,*/*}/src/**/*.ts"
|
|
|
|
const paths = Glob.globSync(pattern, {
|
|
ignore: ["**/internal/**"]
|
|
}).map((path) => Path.resolve(path))
|
|
|
|
const transformer = Path.resolve("scripts/codemods/jsdoc.ts")
|
|
|
|
Jscodeshift.run(transformer, paths, {
|
|
babel: true,
|
|
parser: "ts"
|
|
})
|