feat: add Chocolatey package and Linux/macOS install script with automated publishing

This commit is contained in:
HueByte
2026-02-24 19:44:46 +01:00
parent 38df05df41
commit 045515369c
9 changed files with 339 additions and 10 deletions
+19
View File
@@ -157,3 +157,22 @@ jobs:
EchoHub-Client-linux-arm64.zip
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Publish Chocolatey package
if: steps.changes.outputs.src_changed == 'true' && steps.check_release.outputs.exists == 'false'
run: |
VERSION="${{ steps.version.outputs.version }}"
CHECKSUM=$(sha256sum EchoHub-Client-win-x64.zip | awk '{print $1}')
# Stamp version and checksum into package templates
sed -i "s/__VERSION__/$VERSION/g" packaging/choco/echohub.nuspec
sed -i "s/__VERSION__/$VERSION/g" packaging/choco/tools/chocolateyInstall.ps1
sed -i "s/__CHECKSUM64__/$CHECKSUM/g" packaging/choco/tools/chocolateyInstall.ps1
# Build and push the package
mkdir -p /tmp/choco-out
cd packaging/choco
choco pack echohub.nuspec --output-directory /tmp/choco-out
choco push /tmp/choco-out/echohub.*.nupkg --source https://push.chocolatey.org/ --api-key "$CHOCO_API_KEY"
env:
CHOCO_API_KEY: ${{ secrets.CHOCOLATEY_API_KEY }}