python查看当前计算机系统

import platform

PLATFORM_SYS = platform.system().lower()  # 获得当前平台系统类型名称

# linux系统,PLATFORM_SYS = "linux"
# windows系统,PLATFORM_SYS = "windows"
# mac系统,PLATFORM_SYS = "darwin"
posted on 2023-12-12 11:17  CJTARRR  阅读(29)  评论(0编辑  收藏  举报