Now it's possible ignore session at strtup

This commit is contained in:
Manuel Cortez 2015-01-02 09:55:27 -06:00
parent 29d434bcd4
commit 7d6bf53019
2 changed files with 3 additions and 1 deletions

View File

@ -1,6 +1,7 @@
[sessions]
current_session = string(default="")
sessions = list(default=list())
ignored_sessions = list(default=list())
[app-settings]
language = string(default="system")

View File

@ -7,6 +7,7 @@ import os
import session
import manager
from config_utils import Configuration
import config
class sessionManagerController(object):
def __init__(self):
@ -17,7 +18,7 @@ class sessionManagerController(object):
sessionsList = []
self.sessions = []
for i in os.listdir(paths.config_path()):
if os.path.isdir(paths.config_path(i)):
if os.path.isdir(paths.config_path(i)) and i not in config.app["sessions"]["ignored_sessions"]:
strconfig = "%s/session.conf" % (paths.config_path(i))
config_test = Configuration(strconfig)
name = config_test["twitter"]["user_name"]