def METHOD_NAME(target, ctx):
    src = ctx.rule.file.src
    header = ctx.actions.declare_file(paths.replace_extension(src.path, "head." + src.extension))
    ctx.actions.run(
        inputs = [src],
        outputs = [header],
        tools = [ctx.executable._docheader],
        executable = ctx.executable._docheader,
        arguments = [src.path, header.path],
        mnemonic = "JekyllHeader",
    )
    return [
        _AsciidocHeaderInfo(header = header),
    ]