mirror of
https://github.com/yshtcn/heartbeat.git
synced 2025-12-15 02:30:26 +08:00
Update README.md
This commit is contained in:
parent
d7ed62b5a4
commit
cac9f4efb6
31
README.md
31
README.md
@ -19,3 +19,34 @@
|
|||||||
```
|
```
|
||||||
2023-08-04 11:46:15.306916 Ping: 8ms. Final URL: http://example.com/heartbeat?ping=8. Response status code: 200
|
2023-08-04 11:46:15.306916 Ping: 8ms. Final URL: http://example.com/heartbeat?ping=8. Response status code: 200
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## 执行python源代码
|
||||||
|
如果你需要直接使用源代码,可能需要用到以下几个步骤:
|
||||||
|
|
||||||
|
### 确保安装Python
|
||||||
|
可以从[这里下载最新的python环境](https://python.org/downloads/release/)。
|
||||||
|
|
||||||
|
### 安装必要的python库
|
||||||
|
使用命令行执行以下命令:
|
||||||
|
···
|
||||||
|
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple pystray pillow requests configparser PySocks
|
||||||
|
···
|
||||||
|
|
||||||
|
### 写一个批处理方便执行
|
||||||
|
每次使用py命令并不方便,可以把以下内容保存为bat文件。
|
||||||
|
```
|
||||||
|
@echo off
|
||||||
|
@echo heartbeat start
|
||||||
|
cd /d %~dp0
|
||||||
|
py heartbeat.py
|
||||||
|
pause
|
||||||
|
```
|
||||||
|
|
||||||
|
### 写一个批处理方便执行(静默)
|
||||||
|
如果希望后台运行,可以把以下内容保存为bat文件执行。
|
||||||
|
```
|
||||||
|
@echo off
|
||||||
|
cd /d %~dp0
|
||||||
|
start pythonw heartbeat.py
|
||||||
|
```
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user