Skip to content

feat(global): update all deps #6

feat(global): update all deps

feat(global): update all deps #6

Workflow file for this run

# @format
name: Sync Repos
on:
push:
branches:
- main
# You can add more triggers, such as scheduled events
# schedule:
# - cron: '0 0 * * *'
jobs:
sync:
runs-on: ubuntu-latest
steps:
- name: Checkout source repository
uses: actions/checkout@v2
- name: Push to destination repository
run: |
git config --global user.email "${{ vars.GIT_EMAIL }}"
git config --global user.name "${{ vars.GIT_USERNAME }}"
git clone https://${{ vars.ORG_NAME }}:${{ env.GITHUB_TOKEN }}@github.com/${{ vars.ORG_NAME }}/${{ env.ORIGINAL_REPO_NAME }}.git
cd ${{ env.ORIGINAL_REPO_NAME }}
git remote add ${{ env.ORIGINAL_REPO_NAME }} https://${{ vars.GIT_USERNAME }}:${{ env.GITHUB_TOKEN }}@github.com/${{ vars.GIT_USERNAME }}/${{ env.ORIGINAL_REPO_NAME }}.git
git remote update
git merge ${{ env.ORIGINAL_REPO_NAME }}/main --allow-unrelated-histories
git push origin main
env:
GITHUB_TOKEN: ${{ secrets.PAT }}
ORIGINAL_REPO_NAME: ${{ github.event.repository.name }}