blob: 413293ba63a9ef6bdc558f9598ad8139c5074893 (
plain)
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
|
import platform
from typing import NamedTuple
class SystemInformations(NamedTuple):
"""System Informations Data Structure"""
hostname: str
arch: str
os: str
release: str
def sysinfos_create():
global SYSINFOS
uname = platform.uname()
SYSINFOS=SystemInformations(
uname.node,
uname.machine,
uname.system,
uname.release
)
print(SYSINFOS)
def main():
print("It works!")
sysinfos_create()
|