| 584 | // inputs are execroot-relative and already carry that prefix — strip it so the |
| 585 | // path is not doubled. Mirrors resolveInputPath() in generate_bidi.mjs. |
| 586 | const resolveInput = (p) => { |
| 587 | if (!process.env.BAZEL_BINDIR) return resolve(p) |
| 588 | const prefix = process.env.BAZEL_BINDIR.replaceAll('\\', '/') + '/' |
| 589 | const norm = p.replaceAll('\\', '/') |
| 590 | return resolve(norm.startsWith(prefix) ? norm.slice(prefix.length) : norm) |
| 591 | } |
| 592 | |
| 593 | const { values: args } = parseArgs({ |
| 594 | options: { ast: { type: 'string' }, model: { type: 'string' }, 'dump-schema': { type: 'string' } }, |