Skip to content

Workflow file for this run

name: Release binary auto-uploader
on:
release:
types: [created]
jobs:
release:
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- name: Build Release Binaries
run: cargo build --release
- name: Add artifacts to GH release
uses: softprops/action-gh-release@v1
with:
files: |
target/release/uattool.exe
README.md
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Push release to Chocolatey
run: |
$env:VERSION_STRING = $env:GH_REF_NAME.trimStart("v")
choco apikey --key $env:CHOCO_API_KEY --source https://push.chocolatey.org/
choco pack .\uattool.nuspec --version="$env:VERSION_STRING"
choco push --source https://push.chocolatey.org/
env:
CHOCO_API_KEY: ${{ secrets.CHOCO_API_KEY }}
GH_REF_NAME: ${{ github.ref_name }}