No pnpm dlx
This commit is contained in:
parent
bdde9162d9
commit
1edd6e4193
@ -10,8 +10,11 @@ import { getThemeSrcDirPath } from "../getThemeSrcDirPath";
|
||||
import { getThisCodebaseRootDirPath } from "../tools/getThisCodebaseRootDirPath";
|
||||
import { readThisNpmProjectVersion } from "../tools/readThisNpmProjectVersion";
|
||||
import { keycloakifyBuildOptionsForPostPostBuildScriptEnvName } from "../constants";
|
||||
import { assertNoPnpmDlx } from "../tools/assertNoPnpmDlx";
|
||||
|
||||
export async function main() {
|
||||
assertNoPnpmDlx();
|
||||
|
||||
const buildOptions = readBuildOptions({
|
||||
"processArgv": process.argv.slice(2)
|
||||
});
|
||||
|
14
src/bin/tools/assertNoPnpmDlx.ts
Normal file
14
src/bin/tools/assertNoPnpmDlx.ts
Normal file
@ -0,0 +1,14 @@
|
||||
import { sep as pathSep } from "path";
|
||||
|
||||
export function assertNoPnpmDlx() {
|
||||
if (__dirname.includes(`${pathSep}pnpm${pathSep}dlx${pathSep}`)) {
|
||||
console.log(
|
||||
[
|
||||
"Please don't use `pnpm dlx keycloakify`. Even if you're using pnpm as a package manager",
|
||||
"use `npx keycloakify` or `pnpm exec keycloakify` instead since you want to use the keycloakify version that is installed in your project and",
|
||||
"not the latest version on NPM."
|
||||
].join(" ")
|
||||
);
|
||||
process.exit(1);
|
||||
}
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user