update
PyRun是一个使用Go语言编写的Python脚本管理工具,它可以帮助您管理和运行Python脚本。
# 克隆仓库 git clone <repository-url> cd pyrun # 编译安装 go build -o pyrun # 将编译好的可执行文件移动到PATH路径下
PyRun的配置文件位于 $HOME/.pyrun/conf.toml,首次运行时会自动创建。
$HOME/.pyrun/conf.toml
您可以通过以下环境变量覆盖配置:
PYRUN_SCRIPTS
PYRUN_PYTHON_HOME
# 添加单个脚本 pyrun --add /path/to/script.py # 添加整个目录中的所有Python脚本 pyrun --add /path/to/scripts_directory
# 删除单个脚本 pyrun --del script_name # 删除整个目录 pyrun --del directory_name
pyrun --list
# 运行脚本(不需要.py后缀) pyrun script_name # 运行子目录中的脚本 pyrun subdir/script_name # 带参数运行脚本 pyrun script_name arg1 arg2
pyrun --help
$HOME/.pyrun/ ├── conf.toml # 配置文件 └── scripts/ # 脚本存放目录 ├── script1.py └── subdir/ └── script2.py
MIT
©Copyright 2023 CCF 开源发展委员会 Powered by Trustie& IntelliDE 京ICP备13000930号
PyRun - Python脚本管理器
PyRun是一个使用Go语言编写的Python脚本管理工具,它可以帮助您管理和运行Python脚本。
功能特点
安装
配置
PyRun的配置文件位于
$HOME/.pyrun/conf.toml
,首次运行时会自动创建。您可以通过以下环境变量覆盖配置:
PYRUN_SCRIPTS
: 指定Python脚本的存放路径PYRUN_PYTHON_HOME
: 指定Python解释器的所在路径使用方法
添加脚本或目录
删除脚本或目录
列出所有脚本
运行脚本
查看帮助
目录结构
许可证
MIT