Changeset View
Changeset View
Standalone View
Standalone View
src/workflow/ArcanistDiffWorkflow.php
| Show First 20 Lines • Show All 116 Lines • ▼ Show 20 Lines | $arguments = array( | ||||
| 'help' => pht( | 'help' => pht( | ||||
| 'Read diff from stdin, not from the working copy. This disables '. | 'Read diff from stdin, not from the working copy. This disables '. | ||||
| 'many Arcanist/Phabricator features which depend on having access '. | 'many Arcanist/Phabricator features which depend on having access '. | ||||
| 'to the working copy.'), | 'to the working copy.'), | ||||
| 'conflicts' => array( | 'conflicts' => array( | ||||
| 'less-context' => null, | 'less-context' => null, | ||||
| 'apply-patches' => pht('%s disables lint.', '--raw'), | 'apply-patches' => pht('%s disables lint.', '--raw'), | ||||
| 'never-apply-patches' => pht('%s disables lint.', '--raw'), | 'never-apply-patches' => pht('%s disables lint.', '--raw'), | ||||
| 'advice' => pht('%s disables lint.', '--raw'), | |||||
| 'lintall' => pht('%s disables lint.', '--raw'), | |||||
| 'create' => pht( | 'create' => pht( | ||||
| '%s and %s both need stdin. Use %s.', | '%s and %s both need stdin. Use %s.', | ||||
| '--raw', | '--raw', | ||||
| '--create', | '--create', | ||||
| '--raw-command'), | '--raw-command'), | ||||
| 'edit' => pht( | 'edit' => pht( | ||||
| '%s and %s both need stdin. Use %s.', | '%s and %s both need stdin. Use %s.', | ||||
| '--raw', | '--raw', | ||||
| '--edit', | '--edit', | ||||
| '--raw-command'), | '--raw-command'), | ||||
| 'raw-command' => null, | 'raw-command' => null, | ||||
| ), | ), | ||||
| ), | ), | ||||
| 'raw-command' => array( | 'raw-command' => array( | ||||
| 'param' => 'command', | 'param' => 'command', | ||||
| 'help' => pht( | 'help' => pht( | ||||
| 'Generate diff by executing a specified command, not from the '. | 'Generate diff by executing a specified command, not from the '. | ||||
| 'working copy. This disables many Arcanist/Phabricator features '. | 'working copy. This disables many Arcanist/Phabricator features '. | ||||
| 'which depend on having access to the working copy.'), | 'which depend on having access to the working copy.'), | ||||
| 'conflicts' => array( | 'conflicts' => array( | ||||
| 'less-context' => null, | 'less-context' => null, | ||||
| 'apply-patches' => pht('%s disables lint.', '--raw-command'), | 'apply-patches' => pht('%s disables lint.', '--raw-command'), | ||||
| 'never-apply-patches' => pht('%s disables lint.', '--raw-command'), | 'never-apply-patches' => pht('%s disables lint.', '--raw-command'), | ||||
| 'advice' => pht('%s disables lint.', '--raw-command'), | |||||
| 'lintall' => pht('%s disables lint.', '--raw-command'), | |||||
| ), | ), | ||||
| ), | ), | ||||
| 'create' => array( | 'create' => array( | ||||
| 'help' => pht('Always create a new revision.'), | 'help' => pht('Always create a new revision.'), | ||||
| 'conflicts' => array( | 'conflicts' => array( | ||||
| 'edit' => pht( | 'edit' => pht( | ||||
| '%s can not be used with %s.', | '%s can not be used with %s.', | ||||
| '--create', | '--create', | ||||
| Show All 25 Lines | $arguments = array( | ||||
| ), | ), | ||||
| ), | ), | ||||
| 'nounit' => array( | 'nounit' => array( | ||||
| 'help' => pht('Do not run unit tests.'), | 'help' => pht('Do not run unit tests.'), | ||||
| ), | ), | ||||
| 'nolint' => array( | 'nolint' => array( | ||||
| 'help' => pht('Do not run lint.'), | 'help' => pht('Do not run lint.'), | ||||
| 'conflicts' => array( | 'conflicts' => array( | ||||
| 'lintall' => pht('%s suppresses lint.', '--nolint'), | |||||
| 'advice' => pht('%s suppresses lint.', '--nolint'), | |||||
| 'apply-patches' => pht('%s suppresses lint.', '--nolint'), | 'apply-patches' => pht('%s suppresses lint.', '--nolint'), | ||||
| 'never-apply-patches' => pht('%s suppresses lint.', '--nolint'), | 'never-apply-patches' => pht('%s suppresses lint.', '--nolint'), | ||||
| ), | ), | ||||
| ), | ), | ||||
| 'only' => array( | 'only' => array( | ||||
| 'help' => pht( | 'help' => pht( | ||||
| 'Instead of creating or updating a revision, only create a diff, '. | 'Instead of creating or updating a revision, only create a diff, '. | ||||
| 'which you may later attach to a revision.'), | 'which you may later attach to a revision.'), | ||||
| Show All 13 Lines | $arguments = array( | ||||
| 'less-context' => array( | 'less-context' => array( | ||||
| 'help' => pht( | 'help' => pht( | ||||
| "Normally, files are diffed with full context: the entire file is ". | "Normally, files are diffed with full context: the entire file is ". | ||||
| "sent to Differential so reviewers can 'show more' and see it. If ". | "sent to Differential so reviewers can 'show more' and see it. If ". | ||||
| "you are making changes to very large files with tens of thousands ". | "you are making changes to very large files with tens of thousands ". | ||||
| "of lines, this may not work well. With this flag, a diff will ". | "of lines, this may not work well. With this flag, a diff will ". | ||||
| "be created that has only a few lines of context."), | "be created that has only a few lines of context."), | ||||
| ), | ), | ||||
| 'lintall' => array( | |||||
| 'help' => pht( | |||||
| 'Raise all lint warnings, not just those on lines you changed.'), | |||||
| 'passthru' => array( | |||||
| 'lint' => true, | |||||
| ), | |||||
| ), | |||||
| 'only-new' => array( | |||||
| 'param' => 'bool', | |||||
| 'help' => pht( | |||||
| 'Display only lint messages not present in the original code.'), | |||||
| 'passthru' => array( | |||||
| 'lint' => true, | |||||
| ), | |||||
| ), | |||||
| 'apply-patches' => array( | 'apply-patches' => array( | ||||
| 'help' => pht( | 'help' => pht( | ||||
| 'Apply patches suggested by lint to the working copy without '. | 'Apply patches suggested by lint to the working copy without '. | ||||
| 'prompting.'), | 'prompting.'), | ||||
| 'conflicts' => array( | 'conflicts' => array( | ||||
| 'never-apply-patches' => true, | 'never-apply-patches' => true, | ||||
| ), | ), | ||||
| 'passthru' => array( | 'passthru' => array( | ||||
| ▲ Show 20 Lines • Show All 121 Lines • ▼ Show 20 Lines | $arguments = array( | ||||
| 'Specify the end of the commit range. This disables many '. | 'Specify the end of the commit range. This disables many '. | ||||
| 'Arcanist/Phabricator features which depend on having access to '. | 'Arcanist/Phabricator features which depend on having access to '. | ||||
| 'the working copy.'), | 'the working copy.'), | ||||
| 'supports' => array('git'), | 'supports' => array('git'), | ||||
| 'nosupport' => array( | 'nosupport' => array( | ||||
| 'svn' => pht('Subversion does not support commit ranges.'), | 'svn' => pht('Subversion does not support commit ranges.'), | ||||
| 'hg' => pht('Mercurial does not support %s yet.', '--head'), | 'hg' => pht('Mercurial does not support %s yet.', '--head'), | ||||
| ), | ), | ||||
| 'conflicts' => array( | |||||
| 'lintall' => pht('%s suppresses lint.', '--head'), | |||||
| 'advice' => pht('%s suppresses lint.', '--head'), | |||||
| ), | |||||
| ), | ), | ||||
| ); | ); | ||||
| return $arguments; | return $arguments; | ||||
| } | } | ||||
| public function isRawDiffSource() { | public function isRawDiffSource() { | ||||
| return $this->getArgument('raw') || $this->getArgument('raw-command'); | return $this->getArgument('raw') || $this->getArgument('raw-command'); | ||||
| ▲ Show 20 Lines • Show All 2,553 Lines • Show Last 20 Lines | |||||