From e3c4f59a7727b68afb9d7ff5279b607d6a0e4b1c Mon Sep 17 00:00:00 2001 From: bagas Date: Sun, 28 Dec 2025 13:15:05 +0700 Subject: [PATCH] Add GitHub to Gitea sync workflow --- .github/workflows/sync-to-gitea.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/sync-to-gitea.yml diff --git a/.github/workflows/sync-to-gitea.yml b/.github/workflows/sync-to-gitea.yml new file mode 100644 index 0000000..e3d8d3f --- /dev/null +++ b/.github/workflows/sync-to-gitea.yml @@ -0,0 +1,27 @@ +name: Sync to Gitea + +on: + push: + branches: + - '**' + +jobs: + sync: + runs-on: ubuntu-latest + if: | + github.repository == 'fossyy/tunnel-please' && + !contains(github.event.head_commit.message, '[skip-gitea]') + + steps: + - name: Checkout + uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - name: Push to Gitea + env: + GITEA_TOKEN: ${{ secrets.GITEA_TOKEN }} + GITEA_URL: git.fossy.my.id + run: | + git remote add gitea https://${{ secrets.GITEA_USERNAME }}:${GITEA_TOKEN}@${GITEA_URL}/bagas/tunnel-please.git + git push gitea ${{ github.ref }} --force