Force initial build on keycloakify start
This commit is contained in:
parent
cb9cec676d
commit
d71a2c98d1
@ -17,17 +17,9 @@ export type BuildOptionsLike = {
|
|||||||
assert<BuildOptions extends BuildOptionsLike ? true : false>();
|
assert<BuildOptions extends BuildOptionsLike ? true : false>();
|
||||||
|
|
||||||
export async function appBuild(params: {
|
export async function appBuild(params: {
|
||||||
doSkipIfReactAppBuildDirExists: boolean;
|
|
||||||
buildOptions: BuildOptionsLike;
|
buildOptions: BuildOptionsLike;
|
||||||
}): Promise<{ isAppBuildSuccess: boolean }> {
|
}): Promise<{ isAppBuildSuccess: boolean }> {
|
||||||
const { doSkipIfReactAppBuildDirExists, buildOptions } = params;
|
const { buildOptions } = params;
|
||||||
|
|
||||||
if (
|
|
||||||
doSkipIfReactAppBuildDirExists &&
|
|
||||||
fs.existsSync(buildOptions.reactAppBuildDirPath)
|
|
||||||
) {
|
|
||||||
return { isAppBuildSuccess: true };
|
|
||||||
}
|
|
||||||
|
|
||||||
const { bundler } = buildOptions;
|
const { bundler } = buildOptions;
|
||||||
|
|
||||||
|
@ -84,7 +84,6 @@ export async function command(params: { cliCommandOptions: CliCommandOptions })
|
|||||||
|
|
||||||
{
|
{
|
||||||
const { isAppBuildSuccess } = await appBuild({
|
const { isAppBuildSuccess } = await appBuild({
|
||||||
doSkipIfReactAppBuildDirExists: true,
|
|
||||||
buildOptions
|
buildOptions
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -432,7 +431,6 @@ export async function command(params: { cliCommandOptions: CliCommandOptions })
|
|||||||
console.log(chalk.cyan("Detected changes in the theme. Rebuilding ..."));
|
console.log(chalk.cyan("Detected changes in the theme. Rebuilding ..."));
|
||||||
|
|
||||||
const { isAppBuildSuccess } = await appBuild({
|
const { isAppBuildSuccess } = await appBuild({
|
||||||
doSkipIfReactAppBuildDirExists: false,
|
|
||||||
buildOptions
|
buildOptions
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user