mirror of
https://github.com/develop202/migu_video.git
synced 2025-12-18 07:44:50 +08:00
尝试GitHub拉取gitee内容
This commit is contained in:
30
.github/workflows/update.yml
vendored
Normal file
30
.github/workflows/update.yml
vendored
Normal file
@@ -0,0 +1,30 @@
|
||||
name: update
|
||||
on:
|
||||
workflow_dispatch:
|
||||
# push:
|
||||
schedule:
|
||||
- cron: 2 */2 * * *
|
||||
jobs:
|
||||
run:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 2
|
||||
steps:
|
||||
- name: 检出
|
||||
uses: actions/checkout@v4
|
||||
- name: 拉取Gitee仓库
|
||||
env:
|
||||
GITEE_TOKEN: ${{ secrets.GITEE_TOKEN }}
|
||||
run: git clone https://dream-deve:${GITEE_TOKEN}@gitee.com/dream-deve/migu_video.git
|
||||
- name: 更新内容
|
||||
run: |
|
||||
cp migu_video/interface.txt .
|
||||
cp migu_video/playback.xml .
|
||||
- name: 推送
|
||||
run: |
|
||||
if ! git diff --quiet --exit-code || [ -n "$(git status --porcelain)" ]; then
|
||||
git config user.name "GitHub Actions"
|
||||
git config user.email "actions@github.com"
|
||||
git add .
|
||||
git commit -m "Update by GitHub Actions"
|
||||
git push
|
||||
fi
|
||||
Reference in New Issue
Block a user