Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: add an explicit fetch tag step in release guide #53828

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion doc/contributing/releases.md
Original file line number Diff line number Diff line change
Expand Up @@ -285,6 +285,8 @@ You can integrate the PRs into the proposal without running full CI.
⚠️ At this point, you can either run `git node release --prepare`:

```console
$ # You need to have locally the tag of the latest release of the release line
$ git fetch http://github.com/nodejs/node.git tag -n vx.b.c
Copy link
Member

Choose a reason for hiding this comment

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

Usually git remote update would do this work, won't it? I think it's simpler than checking what was the last tag.

Copy link
Member

Choose a reason for hiding this comment

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

Wouldn't it be better if git node release checked/(optionally?) updated tags?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I do not want to fetch all the tags from the upstream, I really want to fetch what's really necessary – I'm not always in a place with good unlimited internet. I am not going to run git remote update, that's a deal breaker for me.
Updating NCU to check the version number from the changelog instead of a git tag would work.

Copy link
Member

Choose a reason for hiding this comment

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

You can also run git fetch --tags --all. Although it fetches all tags, it also considers your remote state. So, unless your remote hasn't been updated since 2020, it should be quite efficient.

But, doing it on git node release seems good to me as well.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

So, unless your remote hasn't been updated since 2020

Believe it or not, that's probably accurate 😅 One day, a long long time ago, I've cloned the repo with --single-branch, and since then I mostly only pulled the main branch – and until I've tried to prepare a release, that has never caused any problem for me.

$ git node release --prepare x.y.z
```

Expand Down Expand Up @@ -347,7 +349,8 @@ in the repository was not on the current branch you may have to supply a
`--start-ref` argument:

```bash
changelog-maker --group --markdown --filter-release --start-ref v1.2.2
git fetch http://github.com/nodejs/node.git tag -n v1.2.2
changelog-maker --group --markdown --filter-release --start-ref FETCH_HEAD
```

`--filter-release` will remove the release commit from the previous release.
Expand Down
Loading