Skip to content
This repository has been archived by the owner on Aug 20, 2024. It is now read-only.

Commit

Permalink
Add GitHub Actions to mirror GitLab repo
Browse files Browse the repository at this point in the history
The SCP-firmware GitHub repo is now a read-only mirror. A new GitHub
Actions is added to mirror the GitHub repo to SCP-firmware GitLab repo.
The action will fetch GitLab main branch and force push to GitHub
master branch. This will run every day at 8 AM.

Signed-off-by: Wen Ping Teh <[email protected]>
Signed-off-by: Leandro Belli <[email protected]>
Change-Id: Ie58b997ee0a5de3c7c20c6f73dd85d589e2d40ef
  • Loading branch information
wenping-arm authored and leandro-arm committed Feb 15, 2024
1 parent df01400 commit 41cf12c
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/scp_gitlab_mirroring.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
#
# Arm SCP/MCP Software
# Copyright (c) 2024, Arm Limited and Contributors. All rights reserved.
#
# SPDX-License-Identifier: BSD-3-Clause
#

name: Mirror SCP GitLab repo

on:
schedule:
# Runs every day at 8 AM
- cron: '0 8 * * *'


permissions:
contents: write

jobs:
mirror:
name: gitlab-mirror
# Only 1 mirror job needs to run at once
concurrency: mirror
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
# Checks out the github repo
repository: ${{ github.repository }}
path: target-repo
ref: master

- name: Force-push Gitlab -> Github
run: |
cd target-repo &&
git remote add gitlab https://git.gitlab.arm.com/firmware/SCP-firmware.git
git fetch gitlab main
git push -f origin FETCH_HEAD:refs/heads/master --tags

0 comments on commit 41cf12c

Please sign in to comment.