name: Release Plugin run-name: "Release | ${{ inputs.name }} → ${{ inputs.tag }}" on: workflow_dispatch: inputs: payload: description: 'Base64-kodierter JSON-Payload' required: true name: description: 'Plugin Name' required: true tag: description: 'Release Tag' required: true jobs: release-plugin: runs-on: alpine-latest defaults: run: shell: bash steps: - name: Abhängigkeiten installieren shell: sh run: | apk add --no-cache bash jq - name: Daten zusammenstellen id: daten run: | DECODED=$(echo "${{ github.event.inputs.payload }}" | base64 -d) echo "version=$(echo "$DECODED" | jq -r '.version')" >> $GITHUB_OUTPUT echo "channel=$(echo "$DECODED" | jq -r '.channel')" >> $GITHUB_OUTPUT echo "prerelease=$(echo "$DECODED" | jq -r '.prerelease')" >> $GITHUB_OUTPUT echo "zip_folder=$(echo "$DECODED" | jq -r '.zip_folder')" >> $GITHUB_OUTPUT echo "version=$(echo "$DECODED" | jq -r '.version')" echo "channel=$(echo "$DECODED" | jq -r '.channel')" echo "prerelease=$(echo "$DECODED" | jq -r '.prerelease')" echo "zip_folder=$(echo "$DECODED" | jq -r '.zip_folder')" GIT_REPO_URL="https://${RELEASE_TOKEN}:x-oauth-basic@${{ vars.RELEASE_URL }}/${GITHUB_REPOSITORY}.git" echo "git_repo_url=$GIT_REPO_URL" >> $GITHUB_OUTPUT PAYLOAD_REPO=$(echo "$DECODED" | jq -r '.git_url') GIT_PLUGIN_URL="https://${RELEASE_TOKEN}:x-oauth-basic@${{ vars.RELEASE_URL }}/$PAYLOAD_REPO.git" echo "git_plugin_url=$GIT_PLUGIN_URL" >> $GITHUB_OUTPUT - name: Repositorys klonen run: | git clone "$GIT_REPO_URL" repo git clone "$GIT_PLUGIN_URL" plugin ls -la ls -la repo ls -la plugin env: GIT_REPO_URL: ${{ steps.daten.outputs.git_repo_url }} GIT_PLUGIN_URL: ${{ steps.daten.outputs.git_plugin_url }} RELEASE_TOKEN: ${{ secrets.RELEASE_TOKEN }}