This commit is contained in:
@ -30,6 +30,7 @@ export async function command(params: { cliCommandOptions: CliCommandOptions })
|
|||||||
// NOTE: This is arbitrary
|
// NOTE: This is arbitrary
|
||||||
startingFromMajor: 17,
|
startingFromMajor: 17,
|
||||||
excludeMajorVersions: [],
|
excludeMajorVersions: [],
|
||||||
|
doOmitPatch: false,
|
||||||
buildContext
|
buildContext
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -14,9 +14,10 @@ assert<BuildContext extends BuildContextLike ? true : false>();
|
|||||||
export async function promptKeycloakVersion(params: {
|
export async function promptKeycloakVersion(params: {
|
||||||
startingFromMajor: number | undefined;
|
startingFromMajor: number | undefined;
|
||||||
excludeMajorVersions: number[];
|
excludeMajorVersions: number[];
|
||||||
|
doOmitPatch: boolean;
|
||||||
buildContext: BuildContextLike;
|
buildContext: BuildContextLike;
|
||||||
}) {
|
}) {
|
||||||
const { startingFromMajor, excludeMajorVersions, buildContext } = params;
|
const { startingFromMajor, excludeMajorVersions, doOmitPatch, buildContext } = params;
|
||||||
|
|
||||||
const semVersionedTagByMajor = new Map<number, { tag: string; version: SemVer }>();
|
const semVersionedTagByMajor = new Map<number, { tag: string; version: SemVer }>();
|
||||||
|
|
||||||
@ -55,7 +56,8 @@ export async function promptKeycloakVersion(params: {
|
|||||||
});
|
});
|
||||||
|
|
||||||
const lastMajorVersions = Array.from(semVersionedTagByMajor.values()).map(
|
const lastMajorVersions = Array.from(semVersionedTagByMajor.values()).map(
|
||||||
({ version }) => `${version.major}.${version.minor}`
|
({ version }) =>
|
||||||
|
`${version.major}.${version.minor}${doOmitPatch ? "" : `.${version.patch}`}`
|
||||||
);
|
);
|
||||||
|
|
||||||
const { value } = await cliSelect<string>({
|
const { value } = await cliSelect<string>({
|
||||||
|
@ -115,6 +115,7 @@ export async function command(params: { cliCommandOptions: CliCommandOptions })
|
|||||||
const { keycloakVersion } = await promptKeycloakVersion({
|
const { keycloakVersion } = await promptKeycloakVersion({
|
||||||
startingFromMajor: 18,
|
startingFromMajor: 18,
|
||||||
excludeMajorVersions: [22],
|
excludeMajorVersions: [22],
|
||||||
|
doOmitPatch: true,
|
||||||
buildContext
|
buildContext
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user