Skip to content

Commit

Permalink
chore: action to sync repo to codeberg
Browse files Browse the repository at this point in the history
  • Loading branch information
ibhagwan committed Mar 30, 2024
1 parent b9e0352 commit 7ce56a0
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/sync_codeberg.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
on: [push, pull_request]

jobs:
push:
runs-on: ubuntu-latest
if: github.repository == 'ibhagwan/fzf-lua'
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- run: |
mkdir -p ~/.ssh
echo "${{ secrets.GIT_SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
# Ignore hosts keys, since we accept them as-is, add remotes
git config --global core.sshCommand 'ssh -i ~/.ssh/id_rsa -o IdentitiesOnly=yes -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no'
git remote add mirror ssh://[email protected]/ibhagwan/fzf-lua.git
git push --tags --force --prune mirror 'refs/remotes/origin/*:refs/heads/*'

0 comments on commit 7ce56a0

Please sign in to comment.