chore(v2): prepare v2.0.0-beta.0 release (#4774)

* beta.0 version docs + changelog

* fix config for beta switch

* v2.0.0-beta.0
This commit is contained in:
Sébastien Lorber 2021-05-12 16:07:15 +02:00 committed by GitHub
parent fe6492aa87
commit 7e4d7671c8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
103 changed files with 11779 additions and 149 deletions

View file

@ -8,21 +8,18 @@
const path = require('path');
const versions = require('./versions.json');
// This probably only makes sense for the alpha phase, temporary
function getNextAlphaVersionName() {
const expectedPrefix = '2.0.0-alpha.';
// This probably only makes sense for the beta phase, temporary
function getNextBetaVersionName() {
const expectedPrefix = '2.0.0-beta.';
const lastReleasedVersion = versions[0];
if (!lastReleasedVersion.includes(expectedPrefix)) {
throw new Error(
'this code is only meant to be used during the 2.0 alpha phase.',
'this code is only meant to be used during the 2.0 beta phase.',
);
}
const alphaBuild = parseInt(
lastReleasedVersion.replace(expectedPrefix, ''),
10,
);
return `${expectedPrefix}${alphaBuild + 1}`;
const version = parseInt(lastReleasedVersion.replace(expectedPrefix, ''), 10);
return `${expectedPrefix}${version + 1}`;
}
const allDocHomesPaths = [
@ -240,7 +237,7 @@ const isVersioningDisabled = !!process.env.DISABLE_VERSIONING || isI18nStaging;
: undefined,
versions: {
current: {
label: `${getNextAlphaVersionName()} 🚧`,
label: `${getNextBetaVersionName()} 🚧`,
},
},
},