Skip to content

Commit

Permalink
Add script and instructions to generate better release notes (#499)
Browse files Browse the repository at this point in the history
Here's to hoping this doesn't come back to bite us in the back.
  • Loading branch information
rock3r authored Jul 29, 2024
1 parent cd65c40 commit f03989b
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -98,3 +98,6 @@ $RECYCLE.BIN/

# Ignore IJP temp folder
/.intellijPlatform

# Ignore release patch generator output
/this-release.txt
8 changes: 8 additions & 0 deletions RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,13 @@ The release process is mostly automated, but it requires manual prep steps.
the `v1.0.0-*` sub-tags)
8. Create a release from the tag, using the auto-generated release notes. Add any further information that may be useful
to users, including any breaking API or behaviour changes
* You can use an LLM to help you with this step if you want. Use the [generate-release-patch.sh] script to generate
a
patch file with all the changes since the last tag (make sure to run it on main!). You can then use a service like
Gemini Advanced or ChatGPT to generate release notes from it.
* An example prompt that produces decent results with Gemini
Advanced: https://gist.github.com/rock3r/3ed8ec836143049da834505ce5315fce
* **ALWAYS double check** the LLM output. Don't trust it! Treat it only a starting point to help you, not the end
result.
9. Wait for the [publishing CI job](https://github.com/JetBrains/jewel/actions/workflows/publish.yml) to finish running
10. Done!
10 changes: 10 additions & 0 deletions generate-release-patch.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/bash

# Get the latest tag on the current branch
latest_tag=$(git describe --tags --abbrev=0)

# Generate the patch between the latest tag and HEAD
# Extension needs to be txt, as Gemini doesn't let you attach patch files
git format-patch "$latest_tag"..HEAD --stdout > this-release.txt

echo "Patch generated successfully between $latest_tag and HEAD."

0 comments on commit f03989b

Please sign in to comment.