SUBCOMMANDS_RUN_SCRIPTS top-level property

List<FigSubcommand> SUBCOMMANDS_RUN_SCRIPTS
final

Implementation

final List<FigSubcommand> SUBCOMMANDS_RUN_SCRIPTS = [
  Subcommand(
      name: ['run', 'run-script'],
      description: 'Runs a script defined in the package\'s manifest file',
      args: [
        Arg(
            name: 'Scripts',
            filterStrategy: 'fuzzy',
            generators: npmScriptsGenerator,
            isVariadic: true)
      ],
      options: [
        Option(
            name: ['-r', '--recursive'],
            // TS_UNCONVERTED_START (description)
// 'This runs an arbitrary command from each package's "scripts" object. If a package doesn't have the command, it is skipped. If none of the packages have the command, the command fails'
// TS_UNCONVERTED_END
            description: null),
        Option(
            name: '--if-present',
            description:
                'You can use the --if-present flag to avoid exiting with a non-zero exit code when the script is undefined. This lets you run potentially undefined scripts without breaking the execution chain'),
        Option(
            name: '--parallel',
            description:
                'Completely disregard concurrency and topological sorting, running a given script immediately in all matching packages with prefixed streaming output. This is the preferred flag for long-running processes over many packages, for instance, a lengthy build process'),
        Option(
            name: '--stream',
            description:
                'Stream output from child processes immediately, prefixed with the originating package directory. This allows output from different packages to be interleaved'),
        FILTER_OPTION
      ]),
  Subcommand(
      name: 'exec',
      // TS_UNCONVERTED_START (description)
// 'Execute a shell command in scope of a project.
// node_modules/.bin is added to the PATH, so pnpm exec allows executing commands of dependencies'
// TS_UNCONVERTED_END
      description: null,
      args: [
        Arg(
            name: 'Scripts',
            filterStrategy: 'fuzzy',
            generators: dependenciesGenerator,
            isVariadic: true)
      ],
      options: [
        Option(
            name: ['-r', '--recursive'],
            // TS_UNCONVERTED_START (description)
// 'Execute the shell command in every project of the workspace.
// The name of the current package is available through the environment variable PNPM_PACKAGE_NAME (supported from pnpm v2.22.0 onwards)'
// TS_UNCONVERTED_END
            description: null),
        Option(
            name: '--parallel',
            description:
                'Completely disregard concurrency and topological sorting, running a given script immediately in all matching packages with prefixed streaming output. This is the preferred flag for long-running processes over many packages, for instance, a lengthy build process'),
        FILTER_OPTION
      ]),
  Subcommand(
    name: ['test', 't', 'tst'],
    description:
        'Runs an arbitrary command specified in the package\'s test property of its scripts object.\n The intended usage of the property is to specify a command that runs unit or integration testing for your program',
  ),
  Subcommand(
    name: 'start',
    description:
        'Runs an arbitrary command specified in the package\'s start property of its scripts object. If no start property is specified on the scripts object, it will attempt to run node server.js as a default, failing if neither are present.\n The intended usage of the property is to specify a command that starts your program',
  )
];