diff --git a/.github/workflows/gitlab-develop.yml b/.github/workflows/gitlab-develop.yml new file mode 100644 index 000000000..02a670a07 --- /dev/null +++ b/.github/workflows/gitlab-develop.yml @@ -0,0 +1,28 @@ +name: GitLab + +on: + push: + branches: + - develop + +jobs: + sync-with-gitlab: + runs-on: ubuntu-latest + timeout-minutes: 2 + + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 + + - name: Setup git + run: | + git config --global user.name "PDC BOT" + git config --global user.email "pdc@example.com" + + - name: Update branch + run: | + git fetch origin develop + git remote add gitlab https://${{ secrets.GITLAB_TOKEN_NAME }}:${{ secrets.GITLAB_TOKEN }}@${{ secrets.GITLAB_URL }} + git checkout develop + git push -f gitlab -u develop diff --git a/.github/workflows/gitlab-stable.yml b/.github/workflows/gitlab-stable.yml new file mode 100644 index 000000000..c252f63bf --- /dev/null +++ b/.github/workflows/gitlab-stable.yml @@ -0,0 +1,28 @@ +name: GitLab + +on: + push: + branches: + - stable + +jobs: + sync-with-gitlab: + runs-on: ubuntu-latest + timeout-minutes: 2 + + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 + + - name: Setup git + run: | + git config --global user.name "PDC BOT" + git config --global user.email "pdc@example.com" + + - name: Update branch + run: | + git fetch stable + git remote add gitlab https://${{ secrets.GITLAB_TOKEN_NAME }}:${{ secrets.GITLAB_TOKEN }}@${{ secrets.GITLAB_URL }} + git checkout stable + git push -f gitlab -u stable