Let the choice of kc version be auto in GH Action
This commit is contained in:
parent
fa5f1c230a
commit
98f715e652
@ -19,8 +19,6 @@ export function downloadBuiltinKeycloakTheme(params: { keycloakVersion: string;
|
|||||||
|
|
||||||
if (require.main === module) {
|
if (require.main === module) {
|
||||||
(async () => {
|
(async () => {
|
||||||
console.log(process.env);
|
|
||||||
|
|
||||||
const { keycloakVersion } = await promptKeycloakVersion();
|
const { keycloakVersion } = await promptKeycloakVersion();
|
||||||
|
|
||||||
const destDirPath = pathJoin(keycloakThemeBuildingDirPath, "src", "main", "resources", "theme");
|
const destDirPath = pathJoin(keycloakThemeBuildingDirPath, "src", "main", "resources", "theme");
|
||||||
|
@ -19,13 +19,19 @@ export async function promptKeycloakVersion() {
|
|||||||
|
|
||||||
console.log("Initialize the directory with email template from which keycloak version?");
|
console.log("Initialize the directory with email template from which keycloak version?");
|
||||||
|
|
||||||
const { value: keycloakVersion } = await cliSelect<string>({
|
const tags = await getLatestsSemVersionedTag({
|
||||||
"values": await getLatestsSemVersionedTag({
|
|
||||||
"count": 15,
|
"count": 15,
|
||||||
"doIgnoreBeta": true,
|
"doIgnoreBeta": true,
|
||||||
"owner": "keycloak",
|
"owner": "keycloak",
|
||||||
"repo": "keycloak",
|
"repo": "keycloak",
|
||||||
}).then(arr => arr.map(({ tag }) => tag)),
|
}).then(arr => arr.map(({ tag }) => tag));
|
||||||
|
|
||||||
|
if (process.env["GITHUB_ACTIONS"] === "true") {
|
||||||
|
return { "keycloakVersion": tags[0] };
|
||||||
|
}
|
||||||
|
|
||||||
|
const { value: keycloakVersion } = await cliSelect<string>({
|
||||||
|
"values": tags,
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
console.log("Aborting");
|
console.log("Aborting");
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user