# This file was auto generated by Styx.
# Do not edit this file directly.

import typing
import pathlib
from styxdefs import *
import dataclasses

FILE_TOOL_METADATA = Metadata(
    id="cb8493bc920691c7d01b60c7f97dde0b5301728c.boutiques",
    name="file_tool",
    package="afni",
    container_image_tag="afni/afni_make_build:AFNI_24.2.06",
)


class FileToolOutputs(typing.NamedTuple):
    """
    Output object returned when calling `file_tool(...)`.
    """
    root: OutputPathType
    """Output root folder. This is the root folder for all outputs."""
    modified_file: OutputPathType
    """The modified output file"""


def file_tool(
    runner: Runner | None = None,
) -> FileToolOutputs:
    """
    Program to display or modify sections of a file.
    
    Author: AFNI Team
    
    URL: https://afni.nimh.nih.gov/pub/dist/doc/program_help/file_tool.html
    
    Args:
        runner: Command runner.
    Returns:
        NamedTuple of outputs (described in `FileToolOutputs`).
    """
    runner = runner or get_global_runner()
    execution = runner.start_execution(FILE_TOOL_METADATA)
    cargs = []
    cargs.append("file_tool")
    cargs.append("[OPTIONS]")
    cargs.append("-infiles")
    cargs.append("[INPUT_FILES...]")
    ret = FileToolOutputs(
        root=execution.output_file("."),
        modified_file=execution.output_file("[PREFIX]"),
    )
    execution.run(cargs)
    return ret


__all__ = [
    "FILE_TOOL_METADATA",
    "FileToolOutputs",
    "file_tool",
]
