Пример #1
0
def do_reload():
    _config = reload_config(os.path.join(get_work_dir(), config_file), js_file_path, version);
    auth_init(_config);
    utility_init(_config);
    return _config;
Пример #2
0
def do_reload():
    _config = reload_config(os.path.join(get_work_dir(), config_file),
                            js_file_path, version)
    auth_init(_config)
    utility_init(_config)
    return _config
Пример #3
0
        return True;

# parse argv as base dir
config_file = "config.conf";
if len(sys.argv) > 1:
    config_file = sys.argv[1];

# reload the config.
def do_reload():
    _config = reload_config(os.path.join(get_work_dir(), config_file), js_file_path, version);
    auth_init(_config);
    utility_init(_config);
    return _config;
    
# static dir specifies the dir which store static html/js/css/images files.
static_dir = os.path.join(get_work_dir(), "static-dir");
# the js file path, must under the static dir.
js_dir = os.path.join(static_dir, "dynamic-js")
if not os.path.exists(js_dir):
    os.mkdir(js_dir)
js_file_path = os.path.join(js_dir, "conf.js");
# reload config, init log and generate js config file
_config = do_reload();

# init ui tree.
root = Root();
root.redmines = RESTRedmine();
root.reports = RESTDailyReport();
root.users = RESTUser();
root.products = RESTProduct();
root.groups = RESTGroup();
Пример #4
0
config_file = "config.conf"
if len(sys.argv) > 1:
    config_file = sys.argv[1]


# reload the config.
def do_reload():
    _config = reload_config(os.path.join(get_work_dir(), config_file),
                            js_file_path, version)
    auth_init(_config)
    utility_init(_config)
    return _config


# static dir specifies the dir which store static html/js/css/images files.
static_dir = os.path.join(get_work_dir(), "static-dir")
# the js file path, must under the static dir.
js_dir = os.path.join(static_dir, "dynamic-js")
if not os.path.exists(js_dir):
    os.mkdir(js_dir)
js_file_path = os.path.join(js_dir, "conf.js")
# reload config, init log and generate js config file
_config = do_reload()

# init ui tree.
root = Root()
root.redmines = RESTRedmine()
root.reports = RESTDailyReport()
root.users = RESTUser()
root.products = RESTProduct()
root.groups = RESTGroup()