Update gitee.yml

This commit is contained in:
lan-tianxiang
2021-03-26 14:53:56 +08:00
committed by GitHub
parent f9fad99e68
commit 43eaa792ec

View File

@ -1,29 +1,31 @@
name: Gitee repos mirror periodic job
name: sync to gitee
on:
# 如果需要PR触发把push前的#去掉
# push:
schedule:
# 每天北京时间9点跑
- cron: '0 1 * * *'
- cron: '1 0,15 * * *'
workflow_dispatch:
watch:
types: started
push:
branches: [ master ]
repository_dispatch:
types: sync-LXK9301-scripts
jobs:
build:
repo-sync:
env:
dst_key: ${{ secrets.GITEE_PRIVATE_KEY }} # 我自己同步到gitee使用其他人可忽略
runs-on: ubuntu-latest
if: github.event.repository.owner.id == github.event.sender.id
steps:
- name: Mirror the Github organization repos to Gitee.
uses: Yikun/gitee-mirror-action@master
with:
# 必选需要同步的Github用户
src: github/lan-tianxiang
# 必选需要同步到的Gitee的用户目的
dst: gitee/highdimen
# 必选Gitee公钥对应的私钥https://gitee.com/profile/sshkeys
dst_key: ${{ secrets.GITEE_PRIVATE_KEY }}
# 必选Gitee对应的用于创建仓库的tokenhttps://gitee.com/profile/personal_access_tokens
dst_token: ${{ secrets.GITEE_TOKEN }}
clone_style: "ssh"
# 如果是组织指定组织即可默认为用户user
# account_type: org
# 还有黑、白名单,静态名单机制,可以用于更新某些指定库
static_list: "clone_scripts"
# black_list: 'repo_name,repo_name2'
# white_list: 'repo_name,repo_name2'
- uses: actions/checkout@v2
with:
persist-credentials: false
- name: sync github -> gitee
uses: Yikun/hub-mirror-action@master
with:
src: github/lan-tianxiang
dst: gitee/highdimen
static_list: "clone_scripts"
dst_key: ${{ secrets.GITEE_PRIVATE_KEY }}
dst_token: ${{ secrets.GITEE_TOKEN }}
clone_style: "ssh"