chore(workflows): remove sync-github-release-assets.yml workflow file

This commit is contained in:
Ivan
2026-04-17 23:32:00 -05:00
parent a07df2db41
commit 0117e96a45
@@ -1,95 +0,0 @@
# Upstream GitHub (Win/mac CI artifacts): https://github.com/Sudo-Ivan/MeshChatX
# This Gitea project (releases + API uploads): https://git.quad4.io/RNS-Things/MeshChatX
# Secret GITEA_API_URL: API origin https://git.quad4.io (no trailing slash), same as .gitea/workflows/build.yml
#
# Pull Windows/macOS artifacts from GitHub Actions (.github/workflows/build-release.yml) and
# attach them to the Gitea release for the same tag (Linux assets come from build.yml).
#
# On GitHub: tag push runs build-release.yml; branch pushes to "dev" only run .github/workflows/build.yml
# (no Win/mac artifact upload).
#
# Repository secrets:
# GITEA_API_URL, GITEA_TOKEN — same as .gitea/workflows/build.yml
# SYNC_PAT — GitHub PAT: repo + actions:read (list/download workflow artifacts)
#
# Run after the Gitea "Build and Release" job has created the draft (or any release with that tag).
#
# Listed in Actions: use at least one push trigger (not workflow_dispatch alone). Tag push runs sync;
# manual runs use the tag input. Automatic runs skip unless the tagged commit is on origin/dev or
# origin/master (same idea as tagging releases from those branches).
name: Sync GitHub Win/mac release assets
on:
push:
tags:
- "*"
workflow_dispatch:
inputs:
tag:
description: "Tag matching GitHub and Gitea (e.g. v4.4.0)"
required: true
type: string
permissions:
contents: read
env:
GITHUB_SYNC_REPOSITORY: Sudo-Ivan/MeshChatX
GITEA_SYNC_REPOSITORY: RNS-Things/MeshChatX
GITEA_API_URL: ${{ secrets.GITEA_API_URL }}
jobs:
sync:
name: Fetch GitHub artifacts and upload to Gitea release
runs-on: ubuntu-latest
steps:
- name: Clone repository
run: |
set -eu
SERVER="${GITEA_SERVER_URL:-${GITHUB_SERVER_URL:-}}"
REPO="${GITEA_REPOSITORY:-${GITHUB_REPOSITORY:-}}"
if [ -z "$SERVER" ] || [ -z "$REPO" ]; then
echo "Set GITEA_SERVER_URL/GITEA_REPOSITORY or GITHUB_SERVER_URL/GITHUB_REPOSITORY" >&2
exit 1
fi
if [ -n "${GITEA_TOKEN:-}" ] || [ -n "${GITHUB_TOKEN:-}" ]; then
TOKEN="${GITEA_TOKEN:-$GITHUB_TOKEN}"
git config --global credential.helper "!f() { echo username=x-access-token; echo password=${TOKEN}; }; f"
fi
git clone "${SERVER}/${REPO}.git" .
git checkout "${GITHUB_SHA}"
- name: Sync from GitHub Actions
env:
GITHUB_REPOSITORY: ${{ env.GITHUB_SYNC_REPOSITORY }}
GITHUB_PAT: ${{ secrets.SYNC_PAT }}
GITEA_REPOSITORY: ${{ env.GITEA_SYNC_REPOSITORY }}
GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }}
run: |
set -eu
EVENT="${{ github.event_name }}"
if [ "$EVENT" = "workflow_dispatch" ]; then
TAG="${{ inputs.tag || github.event.inputs.tag }}"
else
TAG="${GITHUB_REF#refs/tags/}"
fi
export TAG
if [ -z "${TAG}" ]; then
echo "Could not determine release tag from ref or inputs." >&2
exit 1
fi
if [ "$EVENT" = "push" ]; then
if ! git branch -r --contains HEAD 2>/dev/null | grep -qE 'origin/(dev|master)'; then
echo "Skipping sync: commit is not on origin/dev or origin/master."
exit 0
fi
fi
if [ -z "${GITHUB_PAT:-}" ]; then
echo "Configure secret SYNC_PAT." >&2
exit 1
fi
if [ -z "${GITEA_API_URL:-}" ]; then
echo "Configure secret GITEA_API_URL (https://git.quad4.io for RNS-Things/MeshChatX)." >&2
exit 1
fi
bash scripts/ci/sync-github-release-assets.sh