public function genJsonCommand($source)
    {
        $classNames = [];
        /** @noinspection ForeachSourceInspection */
        /** @noinspection PhpIncludeInspection */
        foreach (require $source as $className) {
            if (preg_match('#^ManaPHP\\\\.*$#', $className)) {
                $classNames[] = $className;
            }
        }

        $output = __DIR__ . '/manaphp_lite.json';
        if ($this->filesystem->fileExists($output)) {
            $data = json_encode($this->filesystem->fileGet($output));
        } else {
            $data = [
                'output' => '@root/manaphp.lite'
            ];
        }

        $data['classes'] = $classNames;

        $this->filesystem->filePut($output, json_encode($data, JSON_PRETTY_PRINT));
        $this->console->writeLn(json_encode($classNames, JSON_PRETTY_PRINT));
    }