projects/prisma7-compatibility-cli/slices/side-by-side-wrapper/walkthrough.md
origin/v7...HEAD43ad8a7891 refactor(cli): infer prisma7 identity from executable, 0e44c96e11 refactor(prisma7): inline CLI delegationce505fa9ad test(client): cover prisma7 compatibility in e2eEstablish a runnable, unpublished prisma7 distribution that delegates to the exact matching Prisma 7 implementation while a direct Prisma dependency continues serving the ordinary prisma command. The slice creates the executable and package boundary that later branding-completion and release-mirroring slices can build on.
prisma/build/index.js through the declared dependency edge.build/prisma7.js executable and forwarded package bundles.prisma7 bin, exact packed dependency semantics, exports, and file set.prisma7/config consumer, exercises the wrapper's version and generation commands with a non-default schema/output, and executes the generated client against SQLite.prisma7 package owns a small executable wrapper and forwards to prisma/build/index.js through its declared dependency. It does not copy CLI implementation, engines, Wasm assets, or command handlers.build/prisma7.js. Each separately bundled CLI consumer normalizes process.argv[1] and parses its filename stem; exact prisma7 selects the compatibility identity, while every other stem defaults to prisma. The same rule handles package-manager shim paths and the real built target without package.json lookup or dependency-path parsing.prisma7, Prisma, client-runtime, and adapter tarballs. Its fixture imports and typechecks prisma7/config, places its schema and generated output outside the defaults, runs the real wrapper's version and generation commands, then performs a SQLite write/read through the generated client. The separate package-manager probe covered npm, pnpm, Yarn node-modules/PnP, Bun, scripts/exec, direct Node, and npm-global launches; custom renamed symlinks and programmatic require() remain unsupported.Adds executable-derived distribution identity: a normalized stem of exactly prisma7 selects prisma7; missing, ordinary, and unsupported executable names select prisma.
prisma7 shim or prisma7.js target, providing a stable identity signal without package metadata or physical dependency-path assumptions.Adds a side-by-side executable wrapper: prisma7 delegates to prisma/build/index.js while preserving normal and completion arguments and delegated exit status.
Adds exact dependency and forwarded package surfaces: the packed wrapper exposes prisma7 and prisma7/config, records an exact same-version Prisma dependency, and resolves its config through that dependency beside a different direct root Prisma.
prisma invocations retain the existing default identity and CLI implementation.require() callers intentionally default to prisma and are outside the supported binary-invocation contract.prisma7 branding, so mixed user-facing references are expected until the next slice.prisma7 branding across command help, initialization, generated config, diagnostics, version/mismatch output, completion, and update handling, including update-prompt suppression.