Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upbuild: snapshot builds incorrectly modify semver versions #20053
Conversation
bb2093a
to
ef43741
|
LGTM Just one comment about wording for an error message |
An interesting case that came up in v10.0.0 with the docs-content. The snapshot release package and docs-content output had various `@breaking-change` notes in the source code referring to `v10.0.0` as certain changes are planned to be made at that point. The snapshot deploy scripts pick up the version from the package.json file and replace it in the output packages with a more concrete version that includes the SHA. This meant that we accidentally also overwrote versions as in the `@breaking-change` notes (ultimately making it difficult for us to use the latest docs-content for the v10 release as it was incorrect). Example snapshot commit: angular/material2-docs-content@e624c71 We fix this by not including the SHA as part of the deployment, but rather including the SHA when building the NPM packages. At that point, we can safely just replace instances of the `0.0.0-PLACEHOLDER` without having to worry about accidental version overriding. To achieve this, we update our release stamping script to have two modes. i.e. snapshot build mode and release mode. Framework does this by checking the Git tag history but that seems less ideal as it makes the release output building reliant on external factors while our stamping is self-contained within the checked out code revision.
ef43741
to
a558cf1
33b31b1
into
angular:master
An interesting case that came up in v10.0.0 with the docs-content. The snapshot release package and docs-content output had various `@breaking-change` notes in the source code referring to `v10.0.0` as certain changes are planned to be made at that point. The snapshot deploy scripts pick up the version from the package.json file and replace it in the output packages with a more concrete version that includes the SHA. This meant that we accidentally also overwrote versions as in the `@breaking-change` notes (ultimately making it difficult for us to use the latest docs-content for the v10 release as it was incorrect). Example snapshot commit: angular/material2-docs-content@e624c71 We fix this by not including the SHA as part of the deployment, but rather including the SHA when building the NPM packages. At that point, we can safely just replace instances of the `0.0.0-PLACEHOLDER` without having to worry about accidental version overriding. To achieve this, we update our release stamping script to have two modes. i.e. snapshot build mode and release mode. Framework does this by checking the Git tag history but that seems less ideal as it makes the release output building reliant on external factors while our stamping is self-contained within the checked out code revision. (cherry picked from commit 33b31b1)
|
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
An interesting case that came up in v10.0.0 with the docs-content. The
snapshot release package and docs-content output had various
@breaking-changenotes in the source code referring tov10.0.0ascertain changes are planned to be made at that point.
The snapshot deploy scripts pick up the version from the package.json
file and replace it in the output packages with a more concrete version
that includes the SHA. This meant that we accidentally also overwrote
versions as in the
@breaking-changenotes (ultimately making itdifficult for us to use the latest docs-content for the v10 release as
it was incorrect).
Example snapshot commit: angular/material2-docs-content@e624c71
We fix this by not including the SHA as part of the deployment, but
rather including the SHA when building the NPM packages. At that point,
we can safely just replace instances of the
0.0.0-PLACEHOLDERwithouthaving to worry about accidental version overriding.
To achieve this, we update our release stamping script to have two
modes. i.e. snapshot build mode and release mode. Framework does this
by checking the Git tag history but that seems less ideal as it makes
the release output building reliant on external factors while our
stamping is self-contained within the checked out code revision.