您的位置:首页 > 运维架构 > Shell

python执行shell脚本

2018-01-06 10:38 363 查看
转自https://www.cnblogs.com/djcsch2001/articles/2025944.html

# -*- coding: utf-8 -*-
import os
file = os.popen("ipconfig")
print(file.read())
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: