Skip to content

Commit ded6bbf

Browse files
committed
Replace bash script with softprops/action-gh-release for dev releases
**Problem:** Bash string escaping inside YAML is a nightmare - double escaping, quoting issues, syntax errors. **Solution:** Use softprops/action-gh-release@v2 with clean YAML multiline strings, matching the pattern used in zlmdb and cfxdb production releases. **Benefits:** - No bash escaping - No string quoting issues - Pure declarative YAML - GitHub Actions expressions work natively in YAML This eliminates all bash/YAML escaping complexity.
1 parent 0f03ccd commit ded6bbf

File tree

1 file changed

+28
-39
lines changed

1 file changed

+28
-39
lines changed

.github/workflows/release.yml

Lines changed: 28 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -178,47 +178,36 @@ jobs:
178178
fi
179179
180180
- name: Create development GitHub release
181+
uses: softprops/action-gh-release@v2
182+
with:
183+
tag_name: ${{ needs.identifiers.outputs.release_name }}
184+
name: Development Build ${{ needs.identifiers.outputs.release_name }}
185+
body: |
186+
## cfxdb Development Build
187+
188+
**Release:** ${{ needs.identifiers.outputs.release_name }}
189+
**Type:** ${{ needs.identifiers.outputs.release_type }}
190+
**Branch:** ${{ needs.identifiers.outputs.base_branch }}
191+
**Commit:** ${{ needs.identifiers.outputs.head_sha }}
192+
193+
This is an automated development/nightly build for testing purposes.
194+
195+
**Installation:**
196+
```bash
197+
pip install https://github.com/crossbario/cfxdb/releases/download/${{ needs.identifiers.outputs.release_name }}/cfxdb-*.whl
198+
```
199+
200+
**Files:**
201+
- Universal wheel (py2.py3-none-any or py3-none-any)
202+
- Source distribution (.tar.gz)
203+
- SHA256 checksums (CHECKSUMS-ALL.sha256)
204+
205+
⚠️ This is a development build - for production use, install from PyPI.
206+
files: dist/*
207+
draft: false
208+
prerelease: true
181209
env:
182210
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
183-
BASE_BRANCH: ${{ needs.identifiers.outputs.base_branch }}
184-
HEAD_SHA: ${{ needs.identifiers.outputs.head_sha }}
185-
run: |
186-
echo "==> Creating development/nightly GitHub release..."
187-
echo "Release type: $RELEASE_TYPE"
188-
echo "Release name: $RELEASE_NAME"
189-
190-
# Delete existing release if it exists (development builds may be rebuilt)
191-
gh release delete "$RELEASE_NAME" --repo "$GITHUB_REPOSITORY" --yes || true
192-
193-
# Create the release
194-
gh release create "$RELEASE_NAME" \
195-
--repo "$GITHUB_REPOSITORY" \
196-
--title "Development Build $RELEASE_NAME" \
197-
--notes "## cfxdb Development Build
198-
199-
**Release:** $RELEASE_NAME
200-
**Type:** $RELEASE_TYPE
201-
**Branch:** $BASE_BRANCH
202-
**Commit:** $HEAD_SHA
203-
204-
This is an automated development/nightly build for testing purposes.
205-
206-
**Installation:**
207-
\`\`\`bash
208-
pip install https://github.com/crossbario/cfxdb/releases/download/$RELEASE_NAME/cfxdb-*.whl
209-
\`\`\`
210-
211-
**Files:**
212-
- Universal wheel (py2.py3-none-any or py3-none-any)
213-
- Source distribution (.tar.gz)
214-
- SHA256 checksums (CHECKSUMS-ALL.sha256)
215-
216-
⚠️ This is a development build - for production use, install from PyPI.
217-
" \
218-
--prerelease \
219-
dist/*
220-
221-
echo "✅ Release $RELEASE_NAME created successfully"
222211

223212
# Production releases (for tagged stable builds) - GitHub + PyPI
224213
release-production:

0 commit comments

Comments
 (0)