AutoApiSS/.github/workflows/randomapi.yml

38 lines
907 B
YAML
Raw Normal View History

2022-12-06 03:42:55 -05:00
#更新api排序
name: update randapi
on:
release:
types: [published]
push:
tags:
- 'v*'
# branches:
# - master
schedule:
- cron: '50 5 * * 1,3,5'
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
2024-04-01 23:34:43 -04:00
uses: actions/checkout@v4
2022-12-06 03:42:55 -05:00
- name: Set up Python #安装python
2024-04-01 23:34:43 -04:00
uses: actions/setup-python@v5
2022-12-06 03:42:55 -05:00
with:
python-version: 3.9
- name: Update randapi #更新api排序
run: |
python updaterand.py
- name: Commit #上传新的排序到仓库
run: |
2024-04-01 23:34:43 -04:00
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --global user.name "github-actions[bot]"
git commit -a -m "update new randapi"
2022-12-06 03:42:55 -05:00
- name: Push changes
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}