Rebuild the theme when properties files changes
This commit is contained in:
parent
0e461fd072
commit
5203813e7b
@ -623,42 +623,52 @@ export async function command(params: {
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
.on("all", async (...[, filePath]) => {
|
.on("all", async (...[, filePath]) => {
|
||||||
ignore_account_spa: {
|
ignore_conditions: {
|
||||||
const doImplementAccountSpa =
|
if (filePath.endsWith(".properties")) {
|
||||||
buildContext.implementedThemeTypes.account.isImplemented &&
|
break ignore_conditions;
|
||||||
buildContext.implementedThemeTypes.account.type === "Single-Page";
|
|
||||||
|
|
||||||
if (!doImplementAccountSpa) {
|
|
||||||
break ignore_account_spa;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (
|
ignore_account_spa: {
|
||||||
!isInside({
|
const doImplementAccountSpa =
|
||||||
dirPath: pathJoin(buildContext.themeSrcDirPath, "account"),
|
buildContext.implementedThemeTypes.account.isImplemented &&
|
||||||
filePath
|
buildContext.implementedThemeTypes.account.type ===
|
||||||
})
|
"Single-Page";
|
||||||
) {
|
|
||||||
break ignore_account_spa;
|
if (!doImplementAccountSpa) {
|
||||||
|
break ignore_account_spa;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (
|
||||||
|
!isInside({
|
||||||
|
dirPath: pathJoin(
|
||||||
|
buildContext.themeSrcDirPath,
|
||||||
|
"account"
|
||||||
|
),
|
||||||
|
filePath
|
||||||
|
})
|
||||||
|
) {
|
||||||
|
break ignore_account_spa;
|
||||||
|
}
|
||||||
|
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
return;
|
ignore_admin: {
|
||||||
}
|
if (!buildContext.implementedThemeTypes.admin.isImplemented) {
|
||||||
|
break ignore_admin;
|
||||||
|
}
|
||||||
|
|
||||||
ignore_admin: {
|
if (
|
||||||
if (!buildContext.implementedThemeTypes.admin.isImplemented) {
|
!isInside({
|
||||||
break ignore_admin;
|
dirPath: pathJoin(buildContext.themeSrcDirPath, "admin"),
|
||||||
|
filePath
|
||||||
|
})
|
||||||
|
) {
|
||||||
|
break ignore_admin;
|
||||||
|
}
|
||||||
|
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (
|
|
||||||
!isInside({
|
|
||||||
dirPath: pathJoin(buildContext.themeSrcDirPath, "admin"),
|
|
||||||
filePath
|
|
||||||
})
|
|
||||||
) {
|
|
||||||
break ignore_admin;
|
|
||||||
}
|
|
||||||
|
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log(`Detected changes in ${filePath}`);
|
console.log(`Detected changes in ${filePath}`);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user