From 83794538f420763f2ff2816b7d843ce796dc9767 Mon Sep 17 00:00:00 2001 From: Magic <82341152+MagicTheDev@users.noreply.github.com> Date: Sat, 17 Aug 2024 10:31:00 -0500 Subject: [PATCH] initial --- .github/workflows/sync.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/sync.yml b/.github/workflows/sync.yml index 4839ade..0cb523c 100644 --- a/.github/workflows/sync.yml +++ b/.github/workflows/sync.yml @@ -11,14 +11,17 @@ jobs: - name: Checkout the private repository uses: actions/checkout@v2 - - name: Remove GitHub Actions workflow directory + - name: Set up SSH run: | - rm -rf .github/workflows/ + mkdir -p ~/.ssh + echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa + chmod 600 ~/.ssh/id_rsa + ssh-keyscan github.com >> ~/.ssh/known_hosts - name: Sync to Public Repo run: | git config --global user.name "MagicTheDev" - git remote add public https://${{ secrets.PAT_TOKEN }}@github.com/ClashKingInc/ClashKingAssets.git + git remote add public git@github.com:ClashKingInc/ClashKingAssets.git git add . git commit -m "Sync to public repo" || echo "No changes to commit" git push --force public main