Update central-sync-logic.yml #5
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Central Logic | ||
| on: | ||
| workflow_call: | ||
| # Inputs... | ||
| jobs: | ||
| run-logic: # Beispiel-Name des Jobs | ||
| runs-on: [self-hosted, vps-debian] | ||
| # BERECHTIGUNGEN NUR HIER DEFINIEREN | ||
| permissions: | ||
| contents: write | ||
| workflows: write | ||
| pull-requests: write # Falls für Automerge benötigt | ||
| if: github.repository != 'lemueIO/.github' | ||
| steps: | ||
| - name: 🧹 Pre-Cleanup | ||
| run: rm -rf ./* ./.git || true | ||
| - name: Checkout | ||
| uses: actions/checkout@v4 | ||
| with: | ||
| ref: main | ||
| fetch-depth: 0 | ||
| - name: Configure Git | ||
| run: | | ||
| git config --global user.name 'github-actions[bot]' | ||
| git config --global user.email 'github-actions[bot]@users.noreply.github.com' | ||
| git config --global --add safe.directory "$GITHUB_WORKSPACE" | ||
| - name: Sync with Upstream | ||
| run: | | ||
| git remote add upstream "${{ inputs.upstream_url }}" || true | ||
| git fetch upstream main | ||
| git merge upstream/main --no-edit || echo "Kein Merge nötig" | ||
| git push origin main | ||