# auto_everything
Linux system automation
#### Installation
`pip3 install auto_everything`
#### Import
```
from auto_everything import Base
base = Base()
```
#### Run command & get reply
```
reply = base.run_command('uname -a')
print(reply)
```
#### Run program
`base.run_program('firefox')`
#### Run python script
`base.run_py('your_python_file_path')`
#### Detect if a program or script is running
```
status = base.is_running('terminal')
print(status)
```
#### Demo
```
from auto_everything import Base
base = Base()
v2ray_path = '/opt/v2ray/v2ray'
chrome_path = '/opt/google/chrome/google-chrome'
# open v2ray
status = base.is_running('v2ray')
if status != True:
base.run_program(v2ray_path)
# open chrome
status = base.is_running('chrome')
if status != True:
base.run_program(chrome_path)
```
PyPI 官网下载 | auto_everything-0.4.tar.gz
版权申诉
52 浏览量
2022-01-26
12:43:13
上传
评论
收藏 3KB GZ 举报
挣扎的蓝藻
- 粉丝: 13w+
- 资源: 15万+
最新资源
- 基于python+Django和协同过滤算法的电影推荐系统+源码(毕业设计&课程设计&项目开发)
- 环境配置 vscode+jupyter
- 项目全部代码,还包含使用到的图片
- 项目全部代码,还包含使用到的图片
- 基于java+MapReduce实现基于物品协同过滤算法,即电影推荐系统+源码+开发文档+算法解析(毕业设计&课程设计&项目开发
- 节点编程(整合所有节点编程代码).7z
- 企业发卡系统源码蓝色UI模板+商户+手机端+对接易支付接口版(无需授权)
- 基于java+Mahout实现协同过滤推荐算法的电影推荐系统+源码(毕业设计&课程设计&项目开发)
- 基于TC72(SPI接口)温度传感器、STM32F103C8T6、LCD1602、FREERTOS的温度采集proteus仿真
- postgresql-42.7.3.jar
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈