-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into pr/env-var-parsing-for-generator-binaryTar…
…gets * master: (69 commits) chore: remove unused printDatamodelDiff (#7686) chore: upgrade pnpm from v5 to v6 (#7685) chore(deps): update devdependencies (non-major) (#7636) chore(deps): update react-prisma (#7637) fix(client): delete transactionId field in middleware (#7662) fix(client): env-var loading (#7669) fix(client): ensure autoinstall looks for the correct client (#7670) fix(seed): add empty export {} for TypeScript --isolatedModules (#7666) fix(migrate): cleanup datasource printing for SQLServer & default to postgres for pg (#7654) fix(cli): remove --provider from init for now (#7667) fix(migrate): Make phrasing of migrate warning messages more accurate (#7664) fix(deps): update engines to v2.25.0-36.c838e79f39885bc8e1611849b1eb28b5bb5bc922 (#7649) chore(deps): update dependency @prisma/studio-server to v0.400.0 (#7645) fix(deps): update engines to v2.25.0-35.ec38a348006215c00435291bf23ddf6096ecccb9 (#7647) fix: disable Node-API with M1 (#7601) fix(deps): update engines to v2.25.0-30.149261944d529dc4c506db7e017bb4dfd26ef398 (#7623) fix(deps): update engines to v2.25.0-29.6d6abdeb152d51c75fcf8ab498150c5a6a79d805 (#7619) refactor(migrate): Simplify engine API of evaluateDataLoss in Migrate (#7576) ci: fix detect-jobs-to-run (#7616) fix(deps): update engines to v2.25.0-28.2456c6fa85cf119868d31902130d1c8401345c53 (#7572) ... # Conflicts: # src/packages/cli/package.json # src/packages/client/package.json # src/packages/engine-core/package.json # src/packages/fetch-engine/package.json # src/packages/migrate/package.json # src/packages/sdk/package.json # src/pnpm-lock.yaml
- Loading branch information
Showing
110 changed files
with
2,904 additions
and
4,367 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
#!/usr/bin/env node | ||
// @ts-check | ||
|
||
const { stdin } = process; | ||
|
||
// From https://github.com/sindresorhus/get-stdin/blob/main/index.js | ||
async function getStdin() { | ||
let result = ""; | ||
|
||
if (stdin.isTTY) { | ||
return result; | ||
} | ||
|
||
stdin.setEncoding("utf8"); | ||
|
||
for await (const chunk of stdin) { | ||
result += chunk; | ||
} | ||
|
||
return result; | ||
} | ||
|
||
async function main() { | ||
const stdinData = await getStdin(); | ||
console.log("stdin:", stdinData); | ||
|
||
/** | ||
* @type string[] | ||
**/ | ||
const filesChanged = JSON.parse(stdinData); | ||
console.log("filesChanged:", filesChanged); | ||
|
||
const jobsToRun = []; | ||
|
||
// If changes are located only in one of the paths below | ||
if ( | ||
filesChanged.every((fileChanged) => | ||
fileChanged.startsWith("src/packages/cli/") | ||
) | ||
) { | ||
jobsToRun.push("-cli-"); | ||
} else if ( | ||
filesChanged.every((fileChanged) => | ||
fileChanged.startsWith("src/packages/client/") | ||
) | ||
) { | ||
jobsToRun.push("-client-"); | ||
jobsToRun.push("-integration-tests-"); | ||
jobsToRun.push("-cli-"); | ||
} else if ( | ||
filesChanged.every((fileChanged) => | ||
fileChanged.startsWith("src/packages/integration-tests/") | ||
) | ||
) { | ||
jobsToRun.push("-integration-tests-"); | ||
} else if ( | ||
filesChanged.every((fileChanged) => | ||
fileChanged.startsWith("src/packages/migrate/") | ||
) | ||
) { | ||
jobsToRun.push("-migrate-"); | ||
jobsToRun.push("-cli-"); | ||
} else { | ||
jobsToRun.push("-all-"); | ||
} | ||
|
||
console.log("jobsToRun:", jobsToRun); | ||
console.log("::set-output name=jobs::" + jobsToRun.join()); | ||
} | ||
|
||
main().then(function () { | ||
console.log("Done"); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.