initial commit
This commit is contained in:
29
. github/workflows/check.yml
Normal file
29
. github/workflows/check.yml
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
name: Run Python Script Every Hour
|
||||||
|
|
||||||
|
on:
|
||||||
|
schedule:
|
||||||
|
- cron: "0 * * * *"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
run-script:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout code
|
||||||
|
uses: actions/checkout@v3
|
||||||
|
|
||||||
|
- name: Setup Python
|
||||||
|
uses: actions/setup-python@v4
|
||||||
|
with:
|
||||||
|
python-version: '3.10'
|
||||||
|
|
||||||
|
- name: Install Dependencies
|
||||||
|
run: |
|
||||||
|
python -m pip install --upgrade pip
|
||||||
|
pip install -r requirements.txt
|
||||||
|
|
||||||
|
- name: Run Python Script
|
||||||
|
env:
|
||||||
|
EITAAEAR_TOKEN: ${{ secrets.EITAAEAR_TOKEN }}
|
||||||
|
run: |
|
||||||
|
python main.py
|
||||||
9
main.py
Normal file
9
main.py
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
import os
|
||||||
|
|
||||||
|
token = os.getenv("EITAAEAR_TOKEN")
|
||||||
|
|
||||||
|
if token:
|
||||||
|
print("Token received successfully!")
|
||||||
|
print("token is:", token)
|
||||||
|
else:
|
||||||
|
print("Token not found.")
|
||||||
1
requirements.txt
Normal file
1
requirements.txt
Normal file
@@ -0,0 +1 @@
|
|||||||
|
requests
|
||||||
Reference in New Issue
Block a user