Skip to content

Conversation

mdjermanovic
Copy link
Member

@mdjermanovic mdjermanovic commented Sep 8, 2024

Prerequisites checklist

What is the purpose of this pull request? (put an "X" next to an item)

[ ] Documentation update
[ ] Bug fix (template)
[ ] New rule (template)
[ ] Changes an existing rule (template)
[ ] Add autofix to a rule
[ ] Add a CLI option
[ ] Add something to the core
[x] Other, please explain:

Refs #18691

Updates main branch to support releasing updates to previous major versions

What changes did you make? (Give an overview)

  • Added release:generate:maintenance script. When this script is run, Makefile.js will pass package tag "maintenance"to eslint-release, which will then publish new release with --tag maintenance on npm and also not mark it as Latest on GitHub (feat: Support updates to previous major versions eslint-release#62). Also, Makefile.js will update a vNN.x docs branch instead of the latest docs branch. We'd add maintenance to the RELEASE_TYPE list on Jenkins.
  • When release is run on a branch that isn't main, Makefile.js will copy over the changelog update to the main branch, and update docs/src/_data/versions.json on the main branch instead of the current branch.
  • Added "Release Parameters" section to manage-releases docs.

Is there anything you'd like reviewers to focus on?

I tested this locally (just had to replace remote commands like git push... with echo git push...) on the main branch (including the case when v8.57.1 has already been released from the v8.x-dev branch) and a future v9.x-dev branch with various scenarios and everything seems to be working fine.

@eslint-github-bot eslint-github-bot bot added the build This change relates to ESLint's build process label Sep 8, 2024
Copy link

netlify bot commented Sep 8, 2024

Deploy Preview for docs-eslint ready!

Name Link
🔨 Latest commit f903728
🔍 Latest deploy log https://app.netlify.com/sites/docs-eslint/deploys/66e83cc14148220008b0a973
😎 Deploy Preview https://deploy-preview-18871--docs-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@mdjermanovic
Copy link
Member Author

This is marked as draft because it needs a new version of eslint-release (eslint/eslint-release#62). Otherwise, it's ready for review.

@mdjermanovic mdjermanovic marked this pull request as ready for review September 11, 2024 12:22
@mdjermanovic mdjermanovic requested a review from a team as a code owner September 11, 2024 12:22

The following table shows examples of the option to select as `RELEASE_TYPE` when starting `eslint-js Release` (the `@eslint/js` package release) and `eslint Release` (the `eslint` package release) jobs on Jenkins to release a new version with the latest features. In both jobs, `main` should be selected as `RELEASE_BRANCH`.

| **Current version** | **Releasing** | **`eslint-js Release`** | **`eslint Release`** |
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm having a bit of trouble understanding this table. Is "Current Version" the equivalent of eslint@latest? I'm also not clear on what the "Releasing" column is meant to indicate. Is that the desired next version?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is "Current Version" the equivalent of eslint@latest?

No, "Current Version" is as described on https://eslint.org/version-support/. For example, when we released 9.0.0-alpha.0, 9.0.0-alpha.0 became the "Current Version".

I'm also not clear on what the "Releasing" column is meant to indicate. Is that the desired next version?

Yes, that's the version that is going to be released.

Any ideas for better names to clarify this?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah ok. "Current" on the version support page refers to the major release line, not a single version.

Looking this over, I think it's confusing to combine settings for eslint and @eslint/js in the same table. For ESLint, we cannot guarantee that 9.25.0 goes to 9.25.1 because it depends on the commits. I think it may be better to separate these into two tables, one for eslint and one for @eslint/js.

As for the wording, maybe this?

  1. "HEAD Version"
  2. "Desired Next Version"
  3. eslint Release Option

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated in 4482729


When releasing a new version of the previous major line, the option to select as `RELEASE_TYPE` depends on whether the current version is a prerelease or not. In both jobs, the corresponding development branch (for example, `v9.x-dev`) should be selected as `RELEASE_BRANCH`.

| **Current version** | **Releasing** | **`eslint-js Release`** | **`eslint Release`** |
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same comment here. I find this format hard to understand.

nzakas
nzakas previously approved these changes Sep 13, 2024
Copy link
Member

@nzakas nzakas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Would like @fasttime to verify before merging.

snitin315
snitin315 previously approved these changes Sep 16, 2024
Copy link
Contributor

@snitin315 snitin315 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mdjermanovic mdjermanovic dismissed stale reviews from snitin315 and nzakas via f903728 September 16, 2024 14:12
Co-authored-by: Nitin Kumar <[email protected]>
Copy link
Member

@fasttime fasttime left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@fasttime fasttime merged commit 959d360 into main Sep 16, 2024
24 checks passed
@fasttime fasttime deleted the main-support-previous-versions branch September 16, 2024 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

build This change relates to ESLint's build process

Projects

Status: Complete

Development

Successfully merging this pull request may close these issues.

4 participants