Filaman/.github/workflows/release.yml

33 lines
782 B
YAML

name: Release
on:
push:
tags:
- 'v*'
jobs:
detect:
runs-on: ubuntu-latest
outputs:
platform: ${{ steps.platform.outputs.platform }}
steps:
- uses: actions/checkout@v4
- name: Determine hosting platform
id: platform
run: |
if [[ "$GITHUB_SERVER_URL" == "https://github.com" ]]; then
echo "platform=github" >> $GITHUB_OUTPUT
else
echo "platform=gitea" >> $GITHUB_OUTPUT
fi
gitea-release:
needs: detect
if: needs.detect.outputs.platform == 'gitea'
uses: ./.github/workflows/providers/gitea-release.yml
github-release:
needs: detect
if: needs.detect.outputs.platform == 'github'
uses: ./.github/workflows/providers/github-release.yml