Skip to content

Commit

Permalink
chore: fix publish script for patches
Browse files Browse the repository at this point in the history
  • Loading branch information
timsuchanek committed Jun 16, 2020
1 parent cf2b715 commit a6b2e96
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions src/scripts/ci/publish.ts
Original file line number Diff line number Diff line change
Expand Up @@ -360,21 +360,14 @@ async function getNewPatchDevVersion(
): Promise<string> {
const minor = getMinorFromPatchBranch(patchBranch)
const currentPatch = await getCurrentPatchForMinor(minor)
const newPatch = currentPatch + 1
const versions = [
...(await getAllVersions(
packages,
'patch-dev',
`2.${minor}.${currentPatch}`,
)),
...(await getAllVersions(
packages,
'patch-beta',
`2.${minor}.${currentPatch}`,
)), // TODO: remove this
...(await getAllVersions(packages, 'patch-dev', `2.${minor}.${newPatch}`)),
...(await getAllVersions(packages, 'patch-beta', `2.${minor}.${newPatch}`)), // TODO: remove this
]
const maxIncrement = getMaxPatchVersionIncrement(versions)

return `2.${minor}.${currentPatch + 1}-dev.${maxIncrement + 1}`
return `2.${minor}.${newPatch}-dev.${maxIncrement + 1}`
}

function getDevVersionIncrements(versions: string[]): number[] {
Expand Down

0 comments on commit a6b2e96

Please sign in to comment.