forked from Naategh/PyCk
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsysInfo.py
More file actions
26 lines (21 loc) · 892 Bytes
/
sysInfo.py
File metadata and controls
26 lines (21 loc) · 892 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/usr/bin/env python
import os, time
import platform
import cpuinfo
os.system("clear")
print("\t"+"#" * 80 + "#")
print("\t"+"#\033[91m\t[*] This is a simple script to show your system information\033[0m\t\t"+ "#")
print("\t"+"#" * 80 + "#")
print("")
def main():
print("\033[91m\tTime: \033[0m" + time.ctime())
print("\033[91m\tCurrent directory: \033[0m" + os.getcwd())
print("\033[91m\tPython Version: \033[0m" + cpuinfo.get_cpu_info()["python_version"])
print("\033[91m\tOperation System: \033[0m" + platform.system())
print("\033[91m\tNode: \033[0m" + platform.node())
print("\033[91m\tOS Version: \033[0m" + platform.uname()[3])
print("\033[91m\tSystem Type: \033[0m" + platform.architecture()[0])
print("\033[91m\tCores: \033[0m" + str(cpuinfo.get_cpu_info()["count"]))
print("\033[91m\tCPU: \033[0m" + cpuinfo.get_cpu_info()["brand"])
if __name__ == "__main__":
main()