git-linter/git_lint/options.py

41 lines
1.5 KiB
Python
Raw Normal View History

2016-09-28 21:26:06 +00:00
import gettext
_ = gettext.gettext
2016-09-28 21:26:06 +00:00
OPTIONS = [
('o', 'only', True,
_('A comma-separated list of only those linters to run'), ['exclude']),
('x', 'exclude', True,
_('A comma-separated list of linters to skip'), []),
('l', 'linters', False,
_('Show the list of configured linters'), []),
('b', 'base', False,
_('Check all changed files in the repository, not just those in the current directory.'), []),
('a', 'all', False,
_('Scan all files in the repository, not just those that have changed.'), []),
('e', 'every', False,
_('Short for -b -a: scan everything'), []),
('w', 'workspace', False,
_('Scan the workspace'), ['staging']),
('s', 'staging', False,
2016-09-30 18:15:10 +00:00
_('Scan the staging area (useful for pre-commit).'), ['monitor']),
('g', 'changes', False,
_("Report lint failures only for diff'd sections"), ['complete']),
('p', 'complete', False,
_('Report lint failures for all files'), []),
('t', 'bylinter', False,
_('Group the reports by linter first as they appear in the config file [default]'), []),
('f', 'byfile', False,
_('Group the reports by file first'), []),
('d', 'dryrun', False,
_('Dry run - report what would be done, but do not run linters'), []),
2016-09-30 18:15:10 +00:00
('m', 'monitor', False,
_('Run continuously, monitoring filesytem for changes'), []),
('c', 'config', True,
_('Path to config file'), []),
('h', 'help', False,
_('This help message'), []),
('v', 'version', False,
_('Version information'), [])
]
2016-09-30 18:15:10 +00:00