Skip to contents

Adds a tool to the toolbox. Can add from built-in registry using tool_name, or from custom YAML file.

Usage

sn_add_tool(
  toolbox,
  tool_name = NULL,
  version = NULL,
  yaml = NULL,
  install = FALSE,
  ...
)

Arguments

toolbox

Toolbox object.

tool_name

Character. Name of the tool (for built-in tools).

version

Character. Version of the tool. If NULL, uses latest for built-in tools.

yaml

Character. Path to custom YAML file (alternative to tool_name).

install

Logical. Whether to install the tool immediately.

...

Additional arguments (reserved for future use).

Value

Updated Toolbox object.

Examples

if (FALSE) { # \dontrun{
# Add built-in tool
toolbox <- sn_add_tool(toolbox, tool_name = "samtools", version = "1.22")

# Add from custom YAML
toolbox <- sn_add_tool(toolbox, yaml = "my_tool.yaml")
} # }