diff --git a/src/Command/CheckDocsCommand.php b/src/Command/CheckDocsCommand.php index c471ac5..5402a22 100644 --- a/src/Command/CheckDocsCommand.php +++ b/src/Command/CheckDocsCommand.php @@ -148,11 +148,12 @@ private function prepareParseQueue(InputInterface $input): ParseQueue $parseQueue = new ParseQueue(); foreach ($files as $filename) { - // Remove ".rst" + // Only parse .rst files if ('.rst' === substr($filename, -4)) { + // Remove ".rst" $filename = substr($filename, 0, -4); + $parseQueue->addFile(ltrim($filename, '/'), true); } - $parseQueue->addFile(ltrim($filename, '/'), true); } return $parseQueue;