Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
if not gi:
raise Exception('Could not get a galaxy connection')
if repo_list_file:
repository_list = load_yaml_file(repo_list_file) # Input file contents
repositories = repository_list['tools'] # The list of tools to install
install_repository_dependencies = repository_list.get(
'install_repository_dependencies', INSTALL_REPOSITORY_DEPENDENCIES)
install_resolver_dependencies = repository_list.get(
'install_resolver_dependencies', INSTALL_RESOLVER_DEPENDENCIES)
install_tool_dependencies = repository_list.get(
'install_tool_dependencies', INSTALL_TOOL_DEPENDENCIES)
elif options.tool_yaml:
repositories = [yaml.safe_load(options.tool_yaml)]
elif options.action == "update":
get_repository_list = GiToToolYaml(
gi=gi,
skip_tool_panel_section_name=False,
get_data_managers=True
)
repository_list = get_repository_list.tool_list
repositories = repository_list['tools']
else:
# An individual tool was specified on the command line
repositories = [{
"owner": options.owner,
"name": options.name,
"tool_panel_section_id": options.tool_panel_section_id,
"tool_panel_section_label": options.tool_panel_section_label,
"tool_shed_url": options.tool_shed_url or MTS,
"revisions": options.revisions
}]