Fix e2e publish test when branching from an older version (#11347)

* Fix e2e publish test when branching from an older version

* Fix

* Fix

* Fix
This commit is contained in:
Nicolò Ribaudo 2020-03-30 18:55:52 +02:00 committed by GitHub
parent c8a8be7221
commit 548cb3ee89
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 13 additions and 7 deletions

View File

@ -243,7 +243,7 @@ ifneq ("$(I_AM_USING_VERDACCIO)", "I_AM_SURE")
exit 1
endif
$(MAKE) prepublish-build
$(YARN) lerna version patch --force-publish=$(FORCE_PUBLISH) --no-push --yes --tag-version-prefix="version-e2e-test-"
$(YARN) lerna version $(VERSION) --force-publish=$(FORCE_PUBLISH) --no-push --yes --tag-version-prefix="version-e2e-test-"
$(YARN) lerna publish from-git --registry http://localhost:4873 --yes --tag-version-prefix="version-e2e-test-"
$(MAKE) clean

View File

@ -13,7 +13,7 @@ source utils/cleanup.sh
function publishESLintPkg {
cd eslint/$1
yarn version --patch --no-git-tag-version
yarn version --new-version $2 --no-git-tag-version
cd ../..
make -j publish-eslint PKG=$1
}
@ -35,11 +35,17 @@ make -j bootstrap-only
startLocalRegistry "$PWD"/scripts/integration-tests/verdaccio-config.yml
loginLocalRegistry
I_AM_USING_VERDACCIO=I_AM_SURE make publish-test
# This script gets the last @babel/standalone version (because it's always published),
# and then increases by one the patch number
VERSION=$(
node -p "'$(npm view @babel/standalone version)'.replace(/(?<=\\d+\\.\\d+\\.)\\d+/, x => ++x)"
)
publishESLintPkg babel-eslint-config-internal
publishESLintPkg babel-eslint-parser
publishESLintPkg babel-eslint-plugin
publishESLintPkg babel-eslint-plugin-development
I_AM_USING_VERDACCIO=I_AM_SURE VERSION="$VERSION" make publish-test
publishESLintPkg babel-eslint-config-internal "$VERSION"
publishESLintPkg babel-eslint-parser "$VERSION"
publishESLintPkg babel-eslint-plugin "$VERSION"
publishESLintPkg babel-eslint-plugin-development "$VERSION"
cleanup