This commit is contained in:
Joseph Garrone
2021-03-01 20:45:37 +01:00
parent 57a0d9f10f
commit f599df2bb7
11 changed files with 617 additions and 158 deletions

View File

@ -2,17 +2,16 @@
import { keycloakThemeBuildingDirPath } from "./build-keycloak-theme";
import { downloadAndUnzip } from "./tools/downloadAndUnzip";
import { join as pathJoin } from "path";
export const keycloakBuiltinThemesAndThirdPartyExamplesThemsUrl =
"https://github.com/garronej/keycloak-react-theming/releases/download/v0.0.1/other_keycloak_thems.zip";
if (require.main === module) {
console.log("execute!");
downloadAndUnzip({
"url": keycloakBuiltinThemesAndThirdPartyExamplesThemsUrl,
"destDirPath": keycloakThemeBuildingDirPath
"destDirPath": pathJoin(keycloakThemeBuildingDirPath, "src", "main", "resources", "theme")
});
}

View File

@ -14,6 +14,8 @@ export function downloadAndUnzip(
fs.mkdirSync(destDirPath, { "recursive": true });
console.log({ url, destDirPath });
[
`wget ${url}`,
...["unzip", "rm"].map(prg => `${prg} ${pathBasename(url)}`),