/* eslint-disable */
// @generated by protobuf-ts 2.11.1 with parameter output_javascript,optimize_code_size,long_type_string,add_pb_suffix,ts_nocheck,eslint_disable
// @generated from protobuf file "runme/runner/v2/config.proto" (package "runme.runner.v2", syntax proto3)
// tslint:disable
// @ts-nocheck
import type { BinaryWriteOptions } from "@protobuf-ts/runtime";
import type { IBinaryWriter } from "@protobuf-ts/runtime";
import type { BinaryReadOptions } from "@protobuf-ts/runtime";
import type { IBinaryReader } from "@protobuf-ts/runtime";
import type { PartialMessage } from "@protobuf-ts/runtime";
import { MessageType } from "@protobuf-ts/runtime";
/**
 * ProgramConfig is a configuration for a program to execute.
 * From this configuration, any program can be built.
 *
 * @generated from protobuf message runme.runner.v2.ProgramConfig
 */
export interface ProgramConfig {
    /**
     * program_name is a name of the program to execute.
     * If it's not a path (relative or absolute), the runner
     * will try to resolve the name.
     * For example: "sh", "/bin/bash".
     *
     * @generated from protobuf field: string program_name = 1
     */
    programName: string;
    /**
     * arguments is a list of arguments passed to the program.
     *
     * @generated from protobuf field: repeated string arguments = 2
     */
    arguments: string[];
    /**
     * directory to execute the program in.
     *
     * @generated from protobuf field: string directory = 3
     */
    directory: string;
    /**
     * language_id associated with script to allow interpreter
     * detection if no specific interpreter program is provided.
     *
     * @generated from protobuf field: string language_id = 4
     */
    languageId: string;
    /**
     * background indicates a background process
     * required to handle running background tasks via CLI in C/I
     *
     * @generated from protobuf field: bool background = 5
     */
    background: boolean;
    /**
     * file_extension associated with script. Some interpreters are strict
     * about file extensions, such as tsc which requires "ts" extension.
     *
     * @generated from protobuf field: string file_extension = 6
     */
    fileExtension: string;
    /**
     * env is a list of additional environment variables
     * that will be injected to the executed program.
     *
     * @generated from protobuf field: repeated string env = 7
     */
    env: string[];
    /**
     * @generated from protobuf oneof: source
     */
    source: {
        oneofKind: "commands";
        /**
         * commands are commands to be executed by the program.
         * The commands are joined and executed as a script.
         *
         * @generated from protobuf field: runme.runner.v2.ProgramConfig.CommandList commands = 8
         */
        commands: ProgramConfig_CommandList;
    } | {
        oneofKind: "script";
        /**
         * script is code to be executed by the program.
         * Individual lines are joined with the new line character.
         *
         * @generated from protobuf field: string script = 9
         */
        script: string;
    } | {
        oneofKind: undefined;
    };
    /**
     * interactive, if true, uses a pseudo-tty to execute the program.
     * Otherwise, the program is executed using in-memory buffers for I/O.
     *
     * @generated from protobuf field: bool interactive = 10
     */
    interactive: boolean;
    /**
     * TODO(adamb): understand motivation for this. In theory, source
     * should tell whether to execute it inline or as a file.
     *
     * @generated from protobuf field: runme.runner.v2.CommandMode mode = 11
     */
    mode: CommandMode;
    /**
     * optional well known id for cell/block
     *
     * @generated from protobuf field: string known_id = 12
     */
    knownId: string;
    /**
     * optional well known name for cell/block
     *
     * @generated from protobuf field: string known_name = 13
     */
    knownName: string;
    /**
     * optional run ID to track the execution of the program
     *
     * @generated from protobuf field: string run_id = 14
     */
    runId: string;
}
/**
 * @generated from protobuf message runme.runner.v2.ProgramConfig.CommandList
 */
export interface ProgramConfig_CommandList {
    /**
     * commands are commands to be executed by the program.
     * The commands are joined and executed as a script.
     * For example: ["echo 'Hello, World'", "ls -l /etc"].
     *
     * @generated from protobuf field: repeated string items = 1
     */
    items: string[];
}
/**
 * @generated from protobuf enum runme.runner.v2.CommandMode
 */
export declare enum CommandMode {
    /**
     * @generated from protobuf enum value: COMMAND_MODE_UNSPECIFIED = 0;
     */
    UNSPECIFIED = 0,
    /**
     * COMMAND_MODE_INLINE indicates that the command should be executed inline.
     * For example: bash -c "echo 'Hello, World'"
     *
     * @generated from protobuf enum value: COMMAND_MODE_INLINE = 1;
     */
    INLINE = 1,
    /**
     * COMMAND_MODE_FILE indicates that the command should be executed as a file.
     * For example: bash /tmp/script.sh
     *
     * @generated from protobuf enum value: COMMAND_MODE_FILE = 2;
     */
    FILE = 2,
    /**
     * COMMAND_MODE_TERMINAL indicates that the command should be executed as a Runme Terminal.
     * This is used by the VS Code extension.
     *
     * @generated from protobuf enum value: COMMAND_MODE_TERMINAL = 3;
     */
    TERMINAL = 3,
    /**
     * COMMAND_MODE_CLI indicates that the command is executed via runme CLI.
     * It is executed as a native command.
     *
     * @generated from protobuf enum value: COMMAND_MODE_CLI = 4;
     */
    CLI = 4
}
declare class ProgramConfig$Type extends MessageType<ProgramConfig> {
    constructor();
    create(value?: PartialMessage<ProgramConfig>): ProgramConfig;
    internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ProgramConfig): ProgramConfig;
    internalBinaryWrite(message: ProgramConfig, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
}
/**
 * @generated MessageType for protobuf message runme.runner.v2.ProgramConfig
 */
export declare const ProgramConfig: ProgramConfig$Type;
declare class ProgramConfig_CommandList$Type extends MessageType<ProgramConfig_CommandList> {
    constructor();
    create(value?: PartialMessage<ProgramConfig_CommandList>): ProgramConfig_CommandList;
    internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: ProgramConfig_CommandList): ProgramConfig_CommandList;
    internalBinaryWrite(message: ProgramConfig_CommandList, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
}
/**
 * @generated MessageType for protobuf message runme.runner.v2.ProgramConfig.CommandList
 */
export declare const ProgramConfig_CommandList: ProgramConfig_CommandList$Type;
export {};
