예제 #1
0
def modules_tool(mod_paths=None):
    """
    Return interface to modules tool (environment modules (C, Tcl), or Lmod)
    """
    # get_modules_tool might return none (e.g. if config was not initialized yet)
    modules_tool = get_modules_tool()
    if modules_tool is not None:
        modules_tool_class = avail_modules_tools().get(modules_tool)
        return modules_tool_class(mod_paths=mod_paths)
    else:
        return None
예제 #2
0
def modules_tool(mod_paths=None, testing=False):
    """
    Return interface to modules tool (environment modules (C, Tcl), or Lmod)
    """
    # get_modules_tool might return none (e.g. if config was not initialized yet)
    modules_tool = get_modules_tool()
    if modules_tool is not None:
        modules_tool_class = avail_modules_tools().get(modules_tool)
        return modules_tool_class(mod_paths=mod_paths, testing=testing)
    else:
        return None
예제 #3
0
def modules_tool(mod_paths=None):
    """
    Return interface to modules tool (environment modules, lmod)
    """
    modules_tool_class = avail_modules_tools().get(get_modules_tool())
    return modules_tool_class(mod_paths=mod_paths)
예제 #4
0
def modules_tool(mod_paths=None):
    """
    Return interface to modules tool (environment modules, lmod)
    """
    modules_tool_class = avail_modules_tools().get(get_modules_tool())
    return modules_tool_class(mod_paths=mod_paths)