Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 5 additions & 26 deletions .github/workflows/mirror.yml
Original file line number Diff line number Diff line change
@@ -1,36 +1,15 @@
# SPDX-License-Identifier: MPL-2.0
name: Mirror to GitLab and Bitbucket
name: Mirror to Git Forges

on:
push:
branches: [ main ]
branches: [main]
workflow_dispatch:

permissions:
contents: read

jobs:
mirror:
name: Mirror repositories
runs-on: ubuntu-latest
if: github.repository == 'hyperpolymath/panic-attack'
steps:
- name: Checkout code
uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd # v5
with:
fetch-depth: 0

- name: Mirror to GitLab
if: vars.GITLAB_MIRROR_ENABLED == 'true'
env:
GITLAB_TOKEN: ${{ secrets.GITLAB_MIRROR_TOKEN }}
run: |
echo "Mirroring to GitLab..."
# git push --mirror https://oauth2:${GITLAB_TOKEN}@gitlab.com/hyperpolymath/panic-attack.git

- name: Mirror to Bitbucket
if: vars.BITBUCKET_MIRROR_ENABLED == 'true'
env:
BITBUCKET_TOKEN: ${{ secrets.BITBUCKET_MIRROR_TOKEN }}
run: |
echo "Mirroring to Bitbucket..."
# git push --mirror https://x-token-auth:${BITBUCKET_TOKEN}@bitbucket.org/hyperpolymath/panic-attack.git
uses: hyperpolymath/standards/.github/workflows/mirror-reusable.yml@e6b2884722350515934d443daf23442f2195796f
secrets: inherit
Loading