name: Upload Kermit binary
description: >-
  Rename the built wermit binary to kermit and upload it as a build
  artifact, for release.yml to download and package later.
inputs:
  label:
    description: >-
      Artifact label, and its final release asset base name, e.g.
      kermit-linux-amd64-11.0 or kermit-freebsd-amd64-11.0
    required: true
runs:
  using: composite
  steps:
    - name: Rename binary for upload
      shell: bash
      run: cp wermit kermit

    - name: Upload binary
      uses: actions/upload-artifact@v4
      with:
        name: ${{ inputs.label }}
        path: |
          kermit
