Page MenuHomePhabricator

If the Script-and-Regex linter captures no "line" text, treat the message as affecting the entire file
ClosedPublic

Authored by epriestley on Jan 12 2016, 1:24 AM.
Tags
None
Referenced Files
F13322173: D15000.id.diff
Fri, Jun 14, 7:40 AM
F13320048: D15000.diff
Thu, Jun 13, 8:30 PM
F13307947: D15000.id36238.diff
Sun, Jun 9, 11:27 PM
F13297450: D15000.diff
Fri, Jun 7, 5:34 AM
F13291518: D15000.id36240.diff
Wed, Jun 5, 12:02 AM
F13291516: D15000.id36238.diff
Wed, Jun 5, 12:02 AM
F13291515: D15000.id36236.diff
Wed, Jun 5, 12:02 AM
F13291514: D15000.id.diff
Wed, Jun 5, 12:02 AM
Subscribers
None

Details

Summary

Fixes T10124.

Test Plan

Added this "linter" to .arclint:

"thing": {
  "type": "script-and-regex",
  "script-and-regex.script": "echo every file is very bad #",
  "script-and-regex.regex": "/^(?P<message>.*)/"
}

...to produce this diff. Also made a variant of it which matches lines to make sure that still works.

Diff Detail

Repository
rARC Arcanist
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

epriestley retitled this revision from to If the Script-and-Regex linter captures no "line" text, treat the message as affecting the entire file.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
chad edited edge metadata.
chad added inline comments.
src/lint/linter/ArcanistScriptAndRegexLinter.php
1

I feel like there should be something spinning here.

This revision is now accepted and ready to land.Jan 12 2016, 1:28 AM
epriestley edited edge metadata.
  • Remove example changes to .arclint now that we've all had a right jolly giggle.
This revision was automatically updated to reflect the committed changes.