added in .gitignore for msinfo32 file, decided on Windows processing and data collection model

This commit is contained in:
Xevion
2019-11-09 20:30:52 -06:00
parent 4319b1d871
commit bc85ff2caf
3 changed files with 23 additions and 5 deletions

3
.gitignore vendored
View File

@@ -1,3 +1,6 @@
# Repository Specific files/folders
/specs/data/**
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]

View File

@@ -1 +0,0 @@
from . import log

View File

@@ -1,5 +1,8 @@
import click
import cpuinfo
import pprint
import os
import platform
import shutil
from . import log
@@ -10,6 +13,19 @@ def cli():
pass
@cli.command()
@clic.option('-c', '--copy', default=False, show_default=True, help='Copy returned specs to the clipboard')
def run():
log.info('specs.run')
@click.option('-c', '--copy', default=False, show_default=True, help='Copy returned specs to the clipboard')
def collect():
systype, sysname = os.name, platform.system()
if os.name == 'nt':
log.info(f'{systype}/{sysname} system detected')
if not shutil.which('msinfo32'):
log.critical('msinfo32 not detected in path')
raise click.ClickException('msinfo32 not detected in path - override to use linux OS specs detection via --linux')
print(
f'{key} : {value}' for key, value in {
'Motherboard' :
}
)
else:
log.critical(f'Unspported Platform \"{systype}\/{sysname}" detected, failing')
return