Skip to content

Commit 2bad6e7

Browse files
📖 document scdiff in the release process (#3730)
* document scdiff in the release process Signed-off-by: Spencer Schrock <[email protected]> * add TOC entry Signed-off-by: Spencer Schrock <[email protected]> * add files to .gitignore we dont want people following the instructions to commit the files accidentally Signed-off-by: Spencer Schrock <[email protected]> --------- Signed-off-by: Spencer Schrock <[email protected]>
1 parent da6d7ec commit 2bad6e7

File tree

2 files changed

+46
-0
lines changed

2 files changed

+46
-0
lines changed

.gitignore

+5
Original file line numberDiff line numberDiff line change
@@ -53,3 +53,8 @@ githubrepo.tar.gz
5353

5454
# goreleaser
5555
dist/*
56+
57+
# scdiff, ensure the files detailed in RELEASE.md aren't committed
58+
repos.txt
59+
oldRelease.json
60+
newRelease.json

RELEASE.md

+41
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ pull request to discuss.)
99
- [Tracking](#tracking)
1010
- [Preparing the release](#preparing-the-release)
1111
- [Validate tests](#validate-tests)
12+
- [Validate the changes with scdiff](#validate-the-changes-with-scdiff)
1213
- [Drafting release notes](#drafting-release-notes)
1314
- [Release](#release)
1415
- [Create a tag](#create-a-tag)
@@ -37,6 +38,46 @@ be merged before releasing the scorecard GitHub Action.
3738

3839
Check the unit tests and integration tests are passing for the planned release commit, either locally or for the GitHub workflows.
3940

41+
### Validate the changes with scdiff
42+
1. Create the list of repos to use for the analysis if you don't have it already:
43+
```console
44+
cat <<EOF > repos.txt
45+
https://github.com/airbnb/lottie-web
46+
https://github.com/apache/tomcat
47+
https://github.com/Azure/azure-functions-dotnet-worker
48+
https://github.com/cncf/xds
49+
https://github.com/google/go-cmp
50+
https://github.com/google/highwayhash
51+
https://github.com/googleapis/google-api-php-client
52+
https://github.com/jacoco/jacoco
53+
https://github.com/ossf/scorecard
54+
https://github.com/pallets/jinja
55+
https://github.com/polymer/polymer
56+
https://github.com/rust-random/getrandom
57+
https://github.com/yaml/libyaml
58+
https://gitlab.com/baserow/baserow
59+
https://gitlab.com/cryptsetup/cryptsetup
60+
EOF
61+
```
62+
2. Run `scdiff` on the previous release:
63+
```console
64+
git checkout <old release tag>
65+
go run cmd/internal/scdiff/main.go generate --repos repos.txt --output oldRelease.json
66+
```
67+
3. Run `scdiff` on the commit to be tagged:
68+
```console
69+
git checkout <commit to be tagged>
70+
go run cmd/internal/scdiff/main.go generate --repos repos.txt --output newRelease.json
71+
```
72+
4. Compare the results:
73+
```console
74+
go run cmd/internal/scdiff/main.go compare oldRelease.json newRelease.json
75+
```
76+
5. Evaluating results:
77+
There will be differences! That's ok, but please pay attention to what they are and use your judgement when evaluating them.
78+
Compare the changes against the release notes you're expecting below.
79+
80+
4081
## Drafting release notes
4182

4283
Release notes are a semi-automated process. We often start by opening [drafting a new release on GitHub](https://github.com/ossf/scorecard/releases/new).

0 commit comments

Comments
 (0)