Commit 62c3bdd1 authored by Romain Bignon's avatar Romain Bignon

start implementation of CLItoDB

import builtins
from import Shell
class CLItoDB(Shell):
def cmdloop(self):
builtins.__xonsh_shell__ = self
builtins.__xonsh_subproc_uncaptured__ = self.sql_cmd
builtins.__xonsh_subproc_captured_stdout__ = self.sql_cmd
builtins.__xonsh_subproc_captured_inject__ = self.sql_cmd
builtins.__xonsh_subproc_captured_object__ = self.sql_cmd
builtins.__xonsh_subproc_captured_hiddenobject__ = self.sql_cmd
builtins.__xonsh_env__['PROMPT'] = '{BOLD_CYAN}{user}{BOLD_WHITE}@{BOLD_GREEN}{hostname}{BOLD_BLUE}:budgea>{NO_COLOR} '
def sql_cmd(self, *args, **kwargs):
print(args, kwargs)
#!/usr/bin/env python3
from clitodb.main import CLItoDB
if __name__ == '__main__':
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment