Skip to content

Commit 9da96c3

Browse files
committed
Update release documentation
1 parent b3fb984 commit 9da96c3

File tree

3 files changed

+120
-5
lines changed

3 files changed

+120
-5
lines changed
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
# Testing Release Notes Configuration
2+
3+
This document explains how to test the automatic release notes generation setup.
4+
5+
## Prerequisites
6+
7+
- You have push access to the repository
8+
- You have the necessary permissions to create releases
9+
10+
## Testing Steps
11+
12+
### 1. Create a Test Branch
13+
14+
```bash
15+
git checkout -b test-release-notes
16+
```
17+
18+
### 2. Make Some Test Changes
19+
20+
Create a few test commits with different types of changes:
21+
22+
```bash
23+
# Feature commit
24+
git commit -m "feat: add new search predicate for date ranges" -m "Adds support for searching date ranges with start and end dates"
25+
26+
# Bug fix commit
27+
git commit -m "fix: resolve issue with null value handling in PostgreSQL" -m "Fixes crash when searching with null values in PostgreSQL adapter"
28+
29+
# Documentation commit
30+
git commit -m "docs: update README with new examples" -m "Adds examples for the new date range predicate"
31+
32+
# Internal/refactor commit
33+
git commit -m "refactor: improve error handling in search builder" -m "Internal refactoring to improve error handling"
34+
```
35+
36+
### 3. Create and Push a Test Tag
37+
38+
```bash
39+
# Create a test tag
40+
git tag v4.4.0-test
41+
42+
# Push the tag (this will trigger the release workflow)
43+
git push origin v4.4.0-test
44+
```
45+
46+
### 4. Check the Results
47+
48+
1. Go to the GitHub repository
49+
2. Navigate to "Releases"
50+
3. Look for the automatically created release with tag `v4.4.0-test`
51+
4. Verify that:
52+
- The release was created automatically
53+
- Release notes were generated
54+
- Changes are categorized correctly
55+
- Internal/refactor commits are excluded or placed in appropriate categories
56+
57+
### 5. Clean Up
58+
59+
After testing, clean up the test tag and branch:
60+
61+
```bash
62+
# Delete the test tag locally and remotely
63+
git tag -d v4.4.0-test
64+
git push origin --delete v4.4.0-test
65+
66+
# Delete the test branch
67+
git checkout main
68+
git branch -D test-release-notes
69+
```
70+
71+
## Expected Behavior
72+
73+
The automatic release notes should:
74+
75+
- ✅ Create a release automatically when a tag is pushed
76+
- ✅ Generate release notes from commits since the last tag
77+
- ✅ Categorize changes appropriately (Features, Bug Fixes, etc.)
78+
- ✅ Exclude or properly categorize internal/maintenance commits
79+
- ✅ Include links to full changelog and documentation
80+
- ✅ Have a professional, consistent format
81+
82+
## Troubleshooting
83+
84+
If the workflow doesn't trigger:
85+
86+
1. Check that the tag follows the pattern `v*` (starts with 'v')
87+
2. Verify the workflow file is in `.github/workflows/release.yml`
88+
3. Check the Actions tab for any workflow failures
89+
4. Ensure you have the necessary permissions
90+
91+
If release notes aren't generated correctly:
92+
93+
1. Check the `.github/release.yml` configuration
94+
2. Verify that commits have appropriate labels or follow conventional commit format
95+
3. Review the workflow logs in the Actions tab
129 KB
Loading

docs/docs/going-further/release_process.md

Lines changed: 25 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,34 @@ In other words: `Major.Minor.Patch`.
2323

2424
To release a new version of Ransack and publish it to RubyGems, take the following steps:
2525

26-
- Create a new release, marked `Prerelease`.
27-
- Update the versions file to the new release, commit and push to `master`.
28-
- Update the [`version.rb`](https://github.com/activerecord-hackery/ransack/lib/ransack/version.rb) file to the new release, commit and push to `master`.
29-
- From the terminal, run the following commands:
26+
### Manual Release Process
27+
28+
1. Update the [`version.rb`](https://github.com/activerecord-hackery/ransack/lib/ransack/version.rb) file to the new release, commit and push to `main`.
29+
2. Create a new release, e.g: v4.4.0 and mark it `Prerelease`.
30+
3. Click the **"Generate release notes"** button to automatically populate the release notes with commits since the last tag.
31+
4. Create and push a tag with the same name:
32+
```bash
33+
git tag v4.4.0
34+
git push origin v4.4.0
35+
```
36+
5. From the terminal, run the following commands:
3037

3138
```bash
3239
rake build
3340
rake release
3441
```
3542

36-
![Create a Release](img/create_release.png)
43+
**GitHub Release UI**
44+
- **Tag**: v4.4.0
45+
- **Target**: main
46+
- **Release title**: v4.4.0 (auto-filled)
47+
- **Release notes**: Click **"Generate release notes"** to auto-populate using the configured categories
48+
- **Set as a pre-release**: **Checked** (required for step 2)
49+
- **Set as the latest release**: Unchecked (correct for prerelease)
50+
- **Action**: Click **"Publish release"** (not "Save draft")
51+
52+
### Release Notes Configuration
53+
54+
The repository includes a release configuration file (`.github/release.yml`) that customizes how release notes are organized when using GitHub's "Generate release notes" button.
55+
56+

0 commit comments

Comments
 (0)