(config: BuildConfig)
| 51 | } |
| 52 | |
| 53 | export async function setReleaseVersion(config: BuildConfig) { |
| 54 | const distTag = String(config.setDistTag); |
| 55 | if (!config.setDistTag || distTag === '') { |
| 56 | // ensure npm dist tag for an actual release |
| 57 | panic(`Invalid npm dist tag "${distTag}"`); |
| 58 | } |
| 59 | |
| 60 | console.log(`💫 Set release npm dist tag: ${distTag}`); |
| 61 | |
| 62 | config.distVersion = await getVersion('release'); |
| 63 | |
| 64 | const validVersion = semver.valid(config.distVersion)!; |
| 65 | if (!validVersion) { |
| 66 | panic(`Invalid semver version "${config.distVersion}"`); |
| 67 | } |
| 68 | |
| 69 | console.log(`🔥 Set release npm version: ${config.distVersion}`); |
| 70 | |
| 71 | // check this @builder.io/qwik version isn't already published |
| 72 | await checkExistingNpmVersion('@builder.io/qwik', config.distVersion); |
| 73 | |
| 74 | // check this @builder.io/qwik-city version isn't already published |
| 75 | await checkExistingNpmVersion('@builder.io/qwik-city', config.distVersion); |
| 76 | } |
| 77 | |
| 78 | export async function prepareReleaseVersion(config: BuildConfig) { |
| 79 | const rootPkg = await readPackageJson(config.rootDir); |
no test coverage detected
searching dependent graphs…