Skip to content

Conversation

aduh95
Copy link
Contributor

@aduh95 aduh95 commented Feb 4, 2021

If an environment variable NODE_RELEASED_VERSIONS is detected, it is
used to validate the version numbers in the YAML comments. At the
notable exception of version numbers 0.0.x and 0.1.x, and the
REPLACEME placeholder, any value not in the list is reported as
invalid.

The idea is to add a script on the node repo GH actions to parse the changelogs to populate the env variable. It won't change anything for doing local linting, but may help spot version errors when reviewing PRs.
For info, it let me spot nodejs/node#37231 and nodejs/node#37232, and I've seen a few times contributors trying to guess the next release version number because they didn't know about REPLACEME.

If an environment variable `NODE_RELEASED_VERSIONS` is detected, it is
used to validate the version numbers in the YAML comments. At the
notable exception of version numbers 0.0.x and 0.1.x,  and the
`REPLACEME` placeholder, any value not in the list is reported as
invalid.
@Trott
Copy link
Member

Trott commented Feb 8, 2021

Might be worth documenting this feature in the README or elsewhere?

@aduh95
Copy link
Contributor Author

aduh95 commented Feb 22, 2021

I think this is ready to land. Thoughts?

@Trott Trott merged commit b74556c into nodejs:master Feb 22, 2021
@aduh95 aduh95 deleted the lint-version-number-changelog branch February 22, 2021 13:28
aduh95 added a commit to aduh95/node that referenced this pull request Mar 6, 2021
danielleadams pushed a commit to nodejs/node that referenced this pull request Mar 16, 2021
targos pushed a commit to nodejs/node that referenced this pull request May 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants