diff options
author | rafael <rafael@blueskyweb.xyz> | 2025-07-24 17:07:11 -0300 |
---|---|---|
committer | rafael <rafael@blueskyweb.xyz> | 2025-07-24 17:07:11 -0300 |
commit | fc2fae42bd8d90fd15b06c14a781efb79bc14e1d (patch) | |
tree | fa073a66b7c27c7fcdd04bb70ee202d51cefec48 /.github | |
parent | dff0332dd0326b446a07d39f70df45aab178e4c4 (diff) | |
download | voidsky-fc2fae42bd8d90fd15b06c14a781efb79bc14e1d.tar.zst |
Add github workflow
Diffstat (limited to '.github')
-rw-r--r-- | .github/workflows/sync-internal.yaml | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/.github/workflows/sync-internal.yaml b/.github/workflows/sync-internal.yaml new file mode 100644 index 000000000..b50d6bc51 --- /dev/null +++ b/.github/workflows/sync-internal.yaml @@ -0,0 +1,31 @@ +name: Sync to internal repo + +on: + push: + branches: [main] + +jobs: + sync: + runs-on: ubuntu-latest + if: github.repository == 'bluesky-social/social-app' + steps: + - name: Checkout public repo + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: Generate GitHub App Token + id: app-token + uses: actions/create-github-app-token@v1 + with: + app-id: ${{ vars.SYNC_INTERNAL_APP_ID }} + private-key: ${{ secrets.SYNC_INTERNAL_PK }} + repositories: social-app-internal + - name: Push to internal repo + env: + TOKEN: ${{ steps.app-token.outputs.token }} + run: | + git config user.name "github-actions" + git config user.email "test@users.noreply.github.com" + git config --unset-all http.https://github.com/.extraheader + git remote add internal https://x-access-token:${TOKEN}@github.com/bluesky-social/social-app-internal.git + git push internal main --force |