Skip to content

Commit b05ceb7

Browse files
committed
docs: add release distribution guide explaining artifact management strategy
1 parent c397384 commit b05ceb7

1 file changed

Lines changed: 80 additions & 0 deletions

File tree

RELEASE-DISTRIBUTION.md

Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,80 @@
1+
# Release Distribution Guide
2+
3+
## Overview
4+
5+
Release artifacts for BiByte are large (43+ MiB with embedded JRE) and are **not stored in this repository** for performance reasons.
6+
7+
## Building Release Artifacts
8+
9+
### Prerequisites
10+
- Java 25 JDK
11+
- Gradle 9.2.0+
12+
- jpackage and jlink tools
13+
14+
### Build Steps
15+
16+
```bash
17+
# Build the project
18+
gradle clean build -x test
19+
20+
# Generate distribution packages
21+
gradle jpackageUberJar # Creates BiByte-2.1.0.jar
22+
gradle jpackageMac # Creates macOS .app bundle and DMG
23+
gradle jpackageWin # Creates Windows EXE and MSI
24+
gradle jpackageLinux # Creates Debian DEB
25+
```
26+
27+
### Output Locations
28+
29+
- **JAR files**: `build/libs/BiByte-*.jar`
30+
- **macOS**: `build/jpackage/BiByte-*.dmg` and `build/jpackage/BiByte.app/`
31+
- **Windows**: `build/jpackage/BiByte-*.exe` and `build/jpackage/BiByte-*.msi`
32+
- **Linux**: `build/jpackage/BiByte-*.deb`
33+
34+
## Distribution Strategy
35+
36+
### For GitHub Releases
37+
1. Use GitHub's **Releases** feature to attach built artifacts
38+
2. Do NOT commit distribution files to the repository
39+
3. Upload artifacts via the GitHub UI or using `gh release upload`
40+
41+
### For Automated CI/CD
42+
Use `.github/workflows/publish-release.yml` workflow to:
43+
1. Build artifacts automatically on tag push
44+
2. Create GitHub Release
45+
3. Upload artifacts directly to release
46+
47+
## .gitignore Rationale
48+
49+
The `release/` directory and build artifacts are ignored because:
50+
- **Large file overhead**: macOS bundle is 174 files, 43+ MiB
51+
- **Slow clone/fetch**: Unnecessary for development
52+
- **Git push timeouts**: HTTP 408 errors on large pushes
53+
- **Duplication**: Built locally on each machine as needed
54+
55+
## Manual Release Publishing
56+
57+
To publish a release manually:
58+
59+
```bash
60+
# 1. Build locally
61+
gradle clean build -x test
62+
gradle jpackageUberJar
63+
64+
# 2. Create GitHub release (using gh CLI)
65+
gh release create v2.1.0 build/libs/BiByte-2.1.0.jar \
66+
--title "Version 2.1.0" \
67+
--notes "Release notes here"
68+
69+
# 3. Or upload to existing release
70+
gh release upload v2.1.0 build/libs/BiByte-2.1.0.jar
71+
```
72+
73+
## Automating with GitHub Actions
74+
75+
The repository includes a reusable workflow that:
76+
1. Builds all distribution packages
77+
2. Creates/updates GitHub Release
78+
3. Uploads artifacts automatically
79+
80+
Trigger by pushing a tag: `git tag v2.1.0 && git push origin v2.1.0`

0 commit comments

Comments
 (0)