Well, this is after the 4/29 turmoil and everything seems to be working... Some of the stuff was not commited before the turmoil. However, it seems intact here... My next plan of action is full "disk" encyption with the P7C_ENC protocol and adding built-in P7C and other apps, converting them into "terminal line" tools.
This commit is contained in:
17
bugpy-mos-0.py
Normal file → Executable file
17
bugpy-mos-0.py
Normal file → Executable file
@@ -6,12 +6,14 @@ from scripts.touch_file import touch_file
|
||||
from scripts.remove import remove
|
||||
from scripts.help import help
|
||||
from scripts.exit import exit
|
||||
from scripts.make_directory import make_directory
|
||||
from scripts.color_print import color_print
|
||||
from pathlib import Path
|
||||
|
||||
# Shitty test
|
||||
# list_files.main()
|
||||
|
||||
if_verbose = 0
|
||||
if_verbose = 0
|
||||
|
||||
def verbose(strings):
|
||||
if if_verbose == 1:
|
||||
@@ -27,7 +29,8 @@ def get_config_line(keyword):
|
||||
config_file = base_dir / "config" / "pointerfile.txt"
|
||||
|
||||
if not config_file.exists():
|
||||
return f"Error: {config_file} not found."
|
||||
color_print.cprint("Error", "DARKRED", sameline=True); print(": config file not found")
|
||||
return None
|
||||
|
||||
# 2. Open and search
|
||||
with config_file.open("r") as f:
|
||||
@@ -54,6 +57,8 @@ def match_command(command, args_list):
|
||||
help.main(args_list)
|
||||
elif command == "exit":
|
||||
exit.main(args_list)
|
||||
elif command == "make_directory":
|
||||
make_directory.main(args_list)
|
||||
# use if else if else if else if to match the output
|
||||
|
||||
def cmdrun(keyword):
|
||||
@@ -68,9 +73,11 @@ def cmdrun(keyword):
|
||||
return False
|
||||
|
||||
if __name__ == "__main__":
|
||||
print("BUGPy-mOS 0 \"Devvie\"")
|
||||
print("\033[2J\033[H")
|
||||
color_print.cprint("BUGPy-mOS 0 ", "GREEN", sameline=True); print("\"Devvie\"")
|
||||
while True:
|
||||
inputs = input("\nBUGS > ")
|
||||
color_print.cprint("BUGS > ", "EMPHASIS", sameline=True)
|
||||
inputs = input()
|
||||
if not inputs.strip() == "":
|
||||
if not cmdrun(inputs):
|
||||
print("BAD COMMAND")
|
||||
color_print.cprint("BAD COMMAND", "DARKRED")
|
||||
|
||||
Reference in New Issue
Block a user