Skip to content

docs: reorder contributors list #83

docs: reorder contributors list

docs: reorder contributors list #83

Workflow file for this run

name: Mirror to Gitee & Gitcode
on:
push:
branches: [main, master, dev]
tags:
- 'v*'
workflow_dispatch:
jobs:
mirror:
name: Mirror Code
runs-on: ubuntu-latest
if: github.repository == 'qinshihu/itops-agent-platform'
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Git
run: |
git config --global user.name "qinshihu"
git config --global user.email "huawei_network@foxmail.com"
- name: Push to Gitee
env:
GITEE_TOKEN: ${{ secrets.GITEE_TOKEN }}
run: |
echo "Setting up Gitee remote..."
git remote add gitee https://oauth2:${GITEE_TOKEN}@gitee.com/IT_Oline/itops-agent-platform.git || git remote set-url gitee https://oauth2:${GITEE_TOKEN}@gitee.com/IT_Oline/itops-agent-platform.git
if [ "${{ github.ref_type }}" = "tag" ]; then
echo "Pushing tags to Gitee..."
git push gitee --tags --force --verbose 2>&1
else
BRANCH="${{ github.ref_name }}"
echo "Pushing branch: $BRANCH to Gitee..."
git push gitee "$BRANCH" --force --verbose 2>&1
fi
echo "Gitee sync completed!"
- name: Push to Gitcode
env:
GITCODE_TOKEN: ${{ secrets.GITCODE_TOKEN }}
run: |
echo "Setting up Gitcode remote..."
git remote add gitcode https://oauth2:${GITCODE_TOKEN}@gitcode.com/gcw_IM7aAihp/itops-agent-platform.git || git remote set-url gitcode https://oauth2:${GITCODE_TOKEN}@gitcode.com/gcw_IM7aAihp/itops-agent-platform.git
if [ "${{ github.ref_type }}" = "tag" ]; then
echo "Pushing tags to Gitcode..."
git push gitcode --tags --force --verbose 2>&1
else
BRANCH="${{ github.ref_name }}"
echo "Pushing branch: $BRANCH to Gitcode..."
git push gitcode "$BRANCH" --force --verbose 2>&1
fi
echo "Gitcode sync completed!"