diff options
author | Santo Cariotti <sancn@live.com> | 2017-08-21 19:25:48 +0200 |
---|---|---|
committer | Santo Cariotti <sancn@live.com> | 2017-08-21 19:25:48 +0200 |
commit | 7d8a51880e9e06fb79cc8d728382b4253246d17c (patch) | |
tree | d654bae2a74fff9a8b1b0f74847906584b63de1f | |
parent | 46e20dca5d9ac795636de326546db21186281e06 (diff) |
deleted "clear shell" function
-rw-r--r-- | lib/app.py | 1 | ||||
-rw-r--r-- | lib/classes.py | 7 | ||||
-rw-r--r-- | lib/commands.py | 4 | ||||
-rw-r--r-- | lib/listcommands.py | 1 |
4 files changed, 2 insertions, 11 deletions
@@ -59,7 +59,6 @@ class Stout(Commands): if __name__ == '__main__': - clear() app = Stout() cmd = '' while cmd != 'quit': diff --git a/lib/classes.py b/lib/classes.py index 92dfe92..1da06f3 100644 --- a/lib/classes.py +++ b/lib/classes.py @@ -1,5 +1,4 @@ import redis, os -import platform try: from .config import config as co @@ -18,11 +17,7 @@ def clear(): """ clear the window """ - nameOs = platform.system() - if nameOs == 'Linux': - os.system('clear') - else: - os.system('clear') + print('\n' * 100) class PersonalError(Exception): diff --git a/lib/commands.py b/lib/commands.py index bb317e0..db464fe 100644 --- a/lib/commands.py +++ b/lib/commands.py @@ -8,9 +8,7 @@ class Commands(object): """ this function is used for execute a command """ - if what == 'clear': - clear() - elif what == 'set': + if what == 'set': try: if cmd[1] == 'user' and cmd[2] is not None: #set name for user if len(cmd[2]) > 10: diff --git a/lib/listcommands.py b/lib/listcommands.py index c779524..987aeb5 100644 --- a/lib/listcommands.py +++ b/lib/listcommands.py @@ -19,7 +19,6 @@ Se utilizzato con il "flag" i, si possono visualizzare le info: get i host, get commands = { 'quit' : None, - 'clear' : None, 'set' : ['user'], 'get' : ['i', ['user', 'host', 'port', 'unix_socket_path', 'db'], 'todo', 'ctodo'], 'add' : None, |