diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..311f13e --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +.env +*.cpython-311.pyc \ No newline at end of file diff --git a/README.md b/README.md deleted file mode 100644 index cb73d00..0000000 --- a/README.md +++ /dev/null @@ -1,2 +0,0 @@ -# TRANSCENDENCE -The last project of the 42 common core \ No newline at end of file diff --git a/command.py b/command.py new file mode 100644 index 0000000..c6588e9 --- /dev/null +++ b/command.py @@ -0,0 +1,12 @@ +class AbstractCommand(): + + def __init__(self, name: str, arg: [str], help_text: str): + self.name = name; + self.arg = arg; + self.help_text = help_text; + + def execute(self): + pass + + def check_arg(self): + pass \ No newline at end of file diff --git a/database.py b/database.py new file mode 100644 index 0000000..f90c39e --- /dev/null +++ b/database.py @@ -0,0 +1 @@ +from \ No newline at end of file diff --git a/login.py b/login.py new file mode 100644 index 0000000..32d264c --- /dev/null +++ b/login.py @@ -0,0 +1,9 @@ +from command import AbstractCommand + +class Login(AbstractCommand): + + def check_arg(self): + return len(self.arg) < 2 + + def execute(self) -> str: + \ No newline at end of file diff --git a/main.py b/main.py new file mode 100644 index 0000000..f4abf3e --- /dev/null +++ b/main.py @@ -0,0 +1,8 @@ +import sys +from command import commands + +import login + +args = sys.argv[1:] + +print(commands[0].__name__) \ No newline at end of file diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..31a68e7 --- /dev/null +++ b/requirements.txt @@ -0,0 +1 @@ +tinydb==4.8.0