Version 1

This commit is contained in:
GamerNoTitle committed 2024-02-06 15:39:51 +08:00
1 parent 813b3d05b2
commit bc70b30a84
6 files changed
+246

No files matched your search

@@ -0,0 +1,35 @@
name: AutoCheckin
on:
workflow_dispatch:
release:
types: [published]
push:
tags:
- 'v*'
# branches:
# - master
schedule:
- cron: "0 2 * * *"
watch:
types: [started]
jobs:
build:
runs-on: ubuntu-latest
# if: github.event.repository.owner.id == github.event.sender.id # 自己点的 start
steps:
- name: Checkout
uses: actions/checkout@master
- name: Set up Python #安装python
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install requirements #安装轮子
run: |
pip install -r requirements.txt
- name: Run script
env:
config: ${{ secrets.SRC_CONFIG }}
run: |
python3 main.py
+32
View File
@@ -0,0 +1,32 @@
name: 'KeepActionAlive'
on:
workflow_dispatch:
schedule:
- cron: '0 0 1 * *'
jobs:
auto_renew:
runs-on: ubuntu-latest
steps:
- name: 'Checkout codes'
uses: actions/checkout@v2
- name: 'Avoid Github Workflow being suspended'
run: echo $(cat /proc/sys/kernel/random/uuid) > UUID.txt
- name: 'Commit Files'
id: commit
run: |
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git add .
git diff --quiet && git diff --staged --quiet || git commit -am '是否继续白嫖:[是] —— 继续白嫖成功!'
echo ::set-output name=status::success
- name: 'GitHub Push'
if: steps.commit.output.status != 'success'
uses: ad-m/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref }}