Skip to content

Commit abce062

Browse files
dbrattliclaude
andcommitted
chore: fix FileVersion warning and add RELEASING.md
- Remove FileVersion from pack-version command as it only accepts numeric versions (e.g., 5.0.0.0), not semver with prerelease tags - Add RELEASING.md documenting the release process and version sync 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
1 parent c6a241a commit abce062

File tree

2 files changed

+79
-1
lines changed

2 files changed

+79
-1
lines changed

RELEASING.md

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
# Releasing Fable.Python
2+
3+
This document describes the release process for Fable.Python and how to keep versions in sync with Fable.
4+
5+
## Version Synchronization with Fable
6+
7+
Fable.Python versions should stay in sync with Fable. For example, if Fable releases `5.0.0-alpha.20`, Fable.Python should release `5.0.0-alpha.20`.
8+
9+
## Release Process
10+
11+
This project uses [release-please](https://github.com/googleapis/release-please) to automate releases. Release-please creates and maintains a release PR that updates automatically as commits are merged to main.
12+
13+
### Standard Release
14+
15+
When the Fable.Python version naturally aligns with Fable (no version override needed):
16+
17+
1. Merge the release-please PR
18+
2. The GitHub Action will create a release and tag
19+
20+
### Forcing a Specific Version
21+
22+
When release-please calculates a different version than Fable (e.g., due to `feat:` commits bumping the minor version), you need to override it:
23+
24+
1. Add `release-as` to `release-please-config.json`:
25+
26+
```json
27+
{
28+
"packages": {
29+
".": {
30+
"release-type": "simple",
31+
"release-as": "5.0.0-alpha.20",
32+
...
33+
}
34+
}
35+
}
36+
```
37+
38+
2. Update `.release-please-manifest.json` if needed:
39+
40+
```json
41+
{
42+
".": "5.0.0-alpha.19"
43+
}
44+
```
45+
46+
The manifest represents the *current* released version. Release-please uses this as the baseline.
47+
48+
3. Commit and push to main (or create a PR)
49+
50+
4. Release-please will update its PR to use the specified version
51+
52+
5. **Important**: After the release, remove `release-as` from the config so future releases calculate versions normally
53+
54+
### Hotfix Releases
55+
56+
If you need to release a fix after syncing with Fable (e.g., a bug found in `5.0.0-alpha.20`):
57+
58+
Use the format `5.0.0-alpha.20.1`, `5.0.0-alpha.20.2`, etc. This:
59+
60+
- Clearly shows the relationship to the base version
61+
- Sorts correctly in package managers
62+
- Resets when the next Fable version is released
63+
64+
## Configuration Files
65+
66+
- `release-please-config.json` - Release-please configuration (release type, version overrides, extra files to update)
67+
- `.release-please-manifest.json` - Tracks the current released version
68+
69+
## Conventional Commits
70+
71+
Release-please uses [conventional commits](https://www.conventionalcommits.org/) to determine version bumps:
72+
73+
- `feat:` - Bumps minor version (in pre-major, due to `bump-minor-pre-major: true`)
74+
- `fix:` - Bumps patch version
75+
- `chore:`, `docs:`, `style:`, `refactor:`, `test:` - No version bump
76+
77+
When syncing with Fable, the automatic version calculation may not match Fable's version, which is why `release-as` is sometimes needed.

justfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,9 @@ pack: build
6565
dotnet pack {{src_path}} -c Release
6666

6767
# Create NuGet package with specific version (used in CI)
68+
# Note: FileVersion must be numeric-only (e.g., 5.0.0.0), so we don't set it for prerelease versions
6869
pack-version version:
69-
dotnet pack {{src_path}} -c Release -p:PackageVersion={{version}} -p:FileVersion={{version}} -p:InformationalVersion={{version}}
70+
dotnet pack {{src_path}} -c Release -p:PackageVersion={{version}} -p:InformationalVersion={{version}}
7071

7172
# Format code with Fantomas
7273
format:

0 commit comments

Comments
 (0)