checkAndFormatSharedOptions top-level property
Implementation
final List<Option> checkAndFormatSharedOptions = [
Option(
name: ['-a', '--all'],
description: 'Run on all files instead of only changed files'
),
Option(
name: ['-n', '--no-fix'],
description: 'Don\'t automatically apply fixes'
),
Option(
name: '--include-existing-autofixes',
description: 'Show autofixes for existing issues'
),
Option(
name: '--force',
description: 'Run on all files, even if ignored'
),
Option(
name: '--diff',
description: 'Diff printing mode',
args: [
Arg(
name: 'mode',
suggestions: [
FigSuggestion(name: 'none'),
FigSuggestion(name: 'compact'),
FigSuggestion(name: 'full')
]
)
]
),
Option(
name: '--filter',
description: 'Filter the set of executed linters and/or the returned codes; use a leading \'-\' to exclude a linter or code',
args: [
Arg(
name: 'linter or code',
isVariadic: true
)
]
),
Option(
name: '--exclude',
description: 'Shorthand for an inverse --filter',
args: [
Arg(
name: 'linter or code',
isVariadic: true
)
]
),
Option(
name: ['-j', '--jobs'],
description: 'Number of concurrent jobs (does not affect background linting)',
args: [
Arg(
name: 'number'
)
]
),
Option(
name: '--sample',
description: 'Run each linter on N files (implies --no-fix and --all if no paths are given)',
args: [
Arg(
name: 'N'
),
Arg(
name: 'paths',
isOptional: true,
isVariadic: true,
template: 'filepaths'
)
]
),
Option(
name: '--upstream',
description: 'Upstream branch used to compute changed files (autodetected by default)',
args: [
Arg(
name: 'branch'
)
]
)
];