Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F2892650
ArcanistGeneratedLinter.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Advanced/Developer...
View Handle
View Hovercard
Size
844 B
Referenced Files
None
Subscribers
None
ArcanistGeneratedLinter.php
View Options
<?php
/**
* Stops other linters from running on generated code.
*/
final
class
ArcanistGeneratedLinter
extends
ArcanistLinter
{
public
function
getInfoName
(
)
{
return
pht
(
'Generated Code'
)
;
}
public
function
getInfoDescription
(
)
{
return
pht
(
'Disables lint for files that are marked as "%s", '
.
'indicating that they contain generated code.'
,
'@'
.
'generated'
)
;
}
public
function
getLinterName
(
)
{
return
'GEN'
;
}
public
function
getLinterPriority
(
)
{
return
0.25
;
}
public
function
getLinterConfigurationName
(
)
{
return
'generated'
;
}
protected
function
canCustomizeLintSeverities
(
)
{
return
false
;
}
protected
function
lintPath
(
ArcanistWorkingCopyPath
$path
)
{
if
(
preg_match
(
'/@'
.
'generated/'
,
$path
->
getData
(
)
)
)
{
$this
->
stopAllLinters
(
)
;
}
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sun, Jan 19, 17:09 (1 w, 5 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1126806
Default Alt Text
ArcanistGeneratedLinter.php (844 B)
Attached To
Mode
rARC Arcanist
Attached
Detach File
Event Timeline
Log In to Comment