kubernetes-csi / csi-release-tools

shared build and test files used by kubernetes-csi projects
Apache License 2.0
21 stars 71 forks source link

Add script to generate patch release notes #237

Closed msau42 closed 7 months ago

msau42 commented 8 months ago

Sample PR: https://github.com/kubernetes-csi/external-provisioner/pull/1061

k8s-ci-robot commented 8 months ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: msau42

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[OWNERS](https://github.com/kubernetes-csi/csi-release-tools/blob/master/OWNERS)~~ [msau42] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
msau42 commented 8 months ago

/release-note-none /assign @sunnylovestiramisu

msau42 commented 8 months ago

@pohly are these tests failing an indication that we did not update release-tools correctly in the other repos?

I tried running the git subtree commands manually on my own fresh external-provisioner branch and it gave strange results.

$ git subtree pull --squash --prefix=release-tools ../csi-release-tools master

$ git log
commit a95373ff5a2909e53afc8d7c8876cc0f4cea4022
Author: Michelle Au <msau@google.com>
Date:   Thu Oct 19 05:52:21 2023 +0000

    Squashed 'release-tools/' changes from f9d5b9c05..c10b67804

    REVERT: f9d5b9c05 Merge pull request #236 from mowangdk/feature/bump_csi-driver-host-path_version
    REVERT: b01fd5372 Bump csi-driver-host-path version up to v1.12.0
    REVERT: 984feece4 Merge pull request #234 from siddhikhapare/csi-tools
    REVERT: 1f7e60599 fixed broken links of testgrid dashboard
    REVERT: de2fba88b Merge pull request #233 from andyzhangx/andyzhangx-patch-1
    REVERT: cee895e1f remove windows 20H2 build since it's EOL long time ago
    REVERT: 670bb0ef1 Merge pull request #229 from marosset/fix-codespell-errors
    REVERT: 35d5e783c Merge pull request #219 from yashsingh74/update-registry
    REVERT: 63473cc96 Merge pull request #231 from coulof/bump-go-version-1.20.5
    REVERT: 29a5c76c7 Merge pull request #228 from mowangdk/chore/adopt_kubernetes_recommand_labels
    REVERT: 8dd28211b Update cloudbuild image with go 1.20.5
    REVERT: 1df23dba6 Merge pull request #230 from msau42/prow
    REVERT: 1f92b7e7c Add ginkgo timeout to e2e tests to help catch any stuck tests
    REVERT: 2b8b80ead fixing some codespell errors
    REVERT: 72984ec0a chore: adopt kubernetes recommand label
    REVERT: 901bcb5a9 Update registry k8s.gcr.io -> registry.k8s.io

    git-subtree-dir: release-tools
    git-subtree-split: c10b67804e07a324fe33595040afd13f020ee000
pohly commented 8 months ago

At first glance, https://github.com/kubernetes-csi/external-provisioner/pull/1050 looks normal.

It also works for me:

$ cd /nvme/gopath/src/github.com/kubernetes-csi/csi-release-tools
$ gh pr checkout --detach https://github.com/kubernetes-csi/csi-release-tools/pull/237
remote: Enumerating objects: 6, done.
....
HEAD is now at 2c625d41 Add script to generate patch release notes

$ cd /nvme/gopath/src/github.com/kubernetes-csi/external-provisioner
$ git fetch origin && git checkout origin/master
...
$ git subtree pull --squash --prefix=release-tools /nvme/gopath/src/github.com/kubernetes-csi/csi-release-tools 2c625d41dda606064eeb1c602e307bc399f4b451
....
Resolving deltas: 100% (282/282), completed with 12 local objects.
From /nvme/gopath/src/github.com/kubernetes-csi/csi-release-tools
 * branch                2c625d41dda606064eeb1c602e307bc399f4b451 -> FETCH_HEAD
hint: Waiting for your editor to close the file... Waiting for Emacs...
Merge made by the 'recursive' strategy.
 release-tools/SIDECAR_RELEASE_PROCESS.md      |  77 ++++++++++++++++++++++++++++++++++-------------------------------------------
 release-tools/generate_patch_release_notes.sh | 106 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 140 insertions(+), 43 deletions(-)
 create mode 100755 release-tools/generate_patch_release_notes.sh
pohly@pohly-desktop:/nvme/gopath/src/github.com/kubernetes-csi/external-provisioner$ git log
commit 9ad994318759084d8806e6156f38d0ef86dddda0 (HEAD)
Merge: ae4c14dfe ff7abf467
Author: Patrick Ohly <patrick.ohly@intel.com>
Date:   Thu Oct 19 16:01:31 2023 +0200

    Merge commit 'ff7abf46771655009bc14798960f41887d7e0063' into HEAD

commit ff7abf46771655009bc14798960f41887d7e0063
Author: Patrick Ohly <patrick.ohly@intel.com>
Date:   Thu Oct 19 16:01:31 2023 +0200

    Squashed 'release-tools/' changes from f9d5b9c05..2c625d41d

    2c625d41d Add script to generate patch release notes

    git-subtree-dir: release-tools
    git-subtree-split: 2c625d41dda606064eeb1c602e307bc399f4b451

commit ae4c14dfe82168a00304ebaf0d991ef61869ab78 (origin/master, origin/HEAD)
...

It also works when I merge your PR into master and then use git subtree pull --squash ... master.

xing-yang commented 7 months ago

/retest

sunnylovestiramisu commented 7 months ago

/lgtm