2021ad12cf
The angular.io production deployment script (`deploy-to-firebase.sh`) compares the major version corresponding to the current branch (e.g. `8` for branch `8.1.x`) against the major stable version (e.g. `9` if the current stable version is `9.1.0`). It then uses the result of that comparison to determine whether the current branch corresponds to a newer version than stable (i.e. an RC version) and thus should not be deployed or to an older version and thus may need to be deployed to an archive vX.angular.io project. Previously, the script was using string comparison (`<`) to compare the two major versions. This could produce incorrect results for an RC major version that is numerically greater than the stable but lexicographically smaller. For example, 10 vs 9 (10 is numerically greater but lexicographically smaller than 9). Example of a CI job that incorrectly tried to deploy an RC branch to production: https://circleci.com/gh/angular/angular/726414 This commit fixes it by switching to an integer comparison (i.e. using the `-lt` operator). PR Close #37426 |
||
---|---|---|
.. | ||
contributors | ||
audit-web-app.js | ||
build-404-page.js | ||
build-artifacts.sh | ||
check-environment.js | ||
create-preview.js | ||
deploy-to-firebase.sh | ||
deploy-to-firebase.test.sh | ||
payload.sh | ||
switch-to-viewengine.js | ||
test-aio-a11y.js | ||
test-preview.js | ||
test-production.sh |