regex-line-length is a linter for use with Phabricator‘s arc command
line tool. This linter is able to identify lines that exceed a certain length while ignoring lines
that match a list of regexes.
Installation
Project-specific
Add this repository as a git submodule.
git submodule init
git submodule add <url for this repo>
Your .arcconfig should list arc-regex-line-length-lint in the load configuration:
regex-line-length linter for arc
regex-line-length is a linter for use with Phabricator‘s
arccommand line tool. This linter is able to identify lines that exceed a certain length while ignoring lines that match a list of regexes.Installation
Project-specific
Add this repository as a git submodule.
Your
.arcconfigshould listarc-regex-line-length-lintin theloadconfiguration:Global
Clone this repository to the same directory where
arcanistandlibphutilare globally located. Your directory structure will look like so:Your
.arcconfigshould listarc-regex-line-length-lintin theloadconfiguration (without a path):Usage
Create a
.arclintfile in the root of your project and add the following content:Feel free to change the include/exclude regexes to suit your project’s needs.
Configuration options
Line length can be configured by providing a
max-line-lengthnumber:Lines can be ignored if they match a given list of regexes. In the following example we ignore lines that include a url.
License
Licensed under the Apache 2.0 license. See LICENSE for details.