naking stuff
This commit is contained in:
parent
62d1d9baca
commit
8d2bb67499
7 changed files with 104 additions and 5 deletions
|
@ -1,5 +1,24 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
|
||||
from . import config
|
||||
from . import output
|
||||
import logging
|
||||
def main() :
|
||||
|
||||
import sys
|
||||
|
||||
__author__ = "arris kathery"
|
||||
__copyright__ = "copyright 2023 brendan berger"
|
||||
__license__ = ""
|
||||
__maintainer__ = "arris kathery"
|
||||
__email__ = "whotookelburg@hotmail.com"
|
||||
__version__ = "0.0.0-alpha0"
|
||||
|
||||
|
||||
def main() -> dict:
|
||||
|
||||
out=output.OutputObject()
|
||||
|
||||
try:
|
||||
# do shit
|
||||
except KeyboardInterrupt:
|
||||
return {'_kbi':True}
|
||||
|
||||
|
|
|
@ -1 +1,9 @@
|
|||
raise "nononono u can't do that! >~<"
|
||||
import owo, sys
|
||||
|
||||
if __name__ == "__main__":
|
||||
output=owo.main()
|
||||
del owo
|
||||
if output._kb:
|
||||
sys.exit()
|
||||
else:
|
||||
# output results
|
||||
|
|
|
@ -1,2 +1,6 @@
|
|||
confDict = {}
|
||||
|
||||
def loadConfig(confLocation = "$HOME/.config/owo.yaml"):
|
||||
|
||||
from os import path
|
||||
if not path.exists(confLocation):
|
||||
|
||||
|
|
44
src/datafiles/__init__.py
Normal file
44
src/datafiles/__init__.py
Normal file
|
@ -0,0 +1,44 @@
|
|||
_config={}
|
||||
_files=[]
|
||||
|
||||
_locations={
|
||||
'_yamlmainconf':[
|
||||
# Check current dir
|
||||
'./owo.yaml',
|
||||
'./owo.yml',
|
||||
'./owo.conf',
|
||||
'./owo.cfg',
|
||||
'./.owo.yaml',
|
||||
'./.owo.yml',
|
||||
'./.owo.conf',
|
||||
'./.owo.cfg',
|
||||
|
||||
# Check home dir
|
||||
'~/owo.yaml',
|
||||
'~/owo.yml',
|
||||
'~/owo.conf',
|
||||
'~/owo.cfg',
|
||||
'~/.owo.yaml',
|
||||
'~/.owo.yml',
|
||||
'~/.owo.conf',
|
||||
'~/.owo.cfg'
|
||||
]
|
||||
}
|
||||
|
||||
from sys import platform
|
||||
|
||||
_locations._yamlmainconf+={
|
||||
'linux':[
|
||||
'{env.HOME}/owo.yaml',
|
||||
'{env.HOME}/owo.yml',
|
||||
'{env.HOME}/owo.conf',
|
||||
'{env.HOME}/owo.cfg',
|
||||
'{env.HOME}/.owo.yaml',
|
||||
'{env.HOME}/.owo.yml',
|
||||
'{env.HOME}/.owo.conf',
|
||||
'{env.HOME}/.owo.cfg'
|
||||
],
|
||||
'linux2':self.linux
|
||||
}[platform]
|
||||
|
||||
def loadConfig(path: str) -> bool:
|
|
@ -1 +0,0 @@
|
|||
import logging
|
24
src/output/OutputObject.py
Normal file
24
src/output/OutputObject.py
Normal file
|
@ -0,0 +1,24 @@
|
|||
import logging
|
||||
|
||||
# outputDict={
|
||||
# 'status': 1,
|
||||
# 'input': {
|
||||
# 'argsRaw': sys.argv,
|
||||
# 'streamObjects': []
|
||||
# },
|
||||
# 'output': [],
|
||||
# 'errors': []
|
||||
# }
|
||||
|
||||
class OutputObject:
|
||||
|
||||
def __init__(self):
|
||||
self.status = 1
|
||||
import sys
|
||||
self.input = {
|
||||
'argsRaw': sys.argv,
|
||||
'streamObjects': []
|
||||
}
|
||||
del sys
|
||||
self.output = []
|
||||
self.errors = []
|
1
src/output/__init__.py
Normal file
1
src/output/__init__.py
Normal file
|
@ -0,0 +1 @@
|
|||
from . import OutputObject
|
Loading…
Reference in a new issue