mirror of
https://github.com/lan-tianxiang/clone_scripts.git
synced 2025-07-15 16:42:36 +08:00
Update gitee.yml
This commit is contained in:
50
.github/workflows/gitee.yml
vendored
50
.github/workflows/gitee.yml
vendored
@ -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对应的用于创建仓库的token,https://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"
|
||||
|
Reference in New Issue
Block a user