1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2024-12-24 14:30:55 +01:00

Filename linter fix for Windows

Summary: On windows paths are separated with \.

Test Plan: - Run filename linter on windows (or some path with \)

Reviewers: epriestley

CC: aran, Koolvin

Differential Revision: https://secure.phabricator.com/D2559
This commit is contained in:
Aurelijus 2012-05-24 10:13:20 +02:00
parent fb4f3c9446
commit c5b7c13c7c

View file

@ -44,7 +44,7 @@ final class ArcanistFilenameLinter extends ArcanistLinter {
} }
public function lintPath($path) { public function lintPath($path) {
if (!preg_match('@^[a-z0-9./_-]+$@i', $path)) { if (!preg_match('@^[a-z0-9./\\\\_-]+$@i', $path)) {
$this->raiseLintAtPath( $this->raiseLintAtPath(
self::LINT_BAD_FILENAME, self::LINT_BAD_FILENAME,
'Name files using only letters, numbers, period, hyphen and '. 'Name files using only letters, numbers, period, hyphen and '.