steps:
  pack:
    image: ubuntu:22.04
    pull: true
    commands:
      - apt update && apt upgrade -y && apt install -y zip
      - xargs -a .pk3include -I% find . -wholename ./% | zip zorch_squadron.pk3 -@
    when:
      - event: [tag]
  publish:
    image: woodpeckerci/plugin-gitea-release
    when:
      - event: [tag]
    settings:
      base_url: https://vcs.otl-hga.net
      files:
        - "zorch_squadron.pk3"
      prerelease: true
      target: trunk
      api_key:
        from_secret: WOODPECKER_CI_TOKEN