soyhuce / classmap-generator
A simple classmap generator extracted from composer
Fund package maintenance!
soyhuce
Installs: 17 911
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 3
Forks: 0
Open Issues: 2
Requires
- php: ^8.2
- symfony/finder: ^6.2.7||^7.0
Requires (Dev)
- composer/composer: ^2.2
- friendsofphp/php-cs-fixer: ^3.0
- pestphp/pest: ^2.0
- phpstan/phpstan: ^1.4
This package is auto-updated.
Last update: 2024-12-16 16:25:39 UTC
README
Generates classmap without composer.
\Soyhuce\ClassMapGenerator\ClassMapGenerator::createMap(__DIR__ . '/src'); // [ // 'Soyhuce\\ClassmapGenerator\\ClassmapGenerator' => '/code/soyhuce/classmap-generator/src/ClassmapGenerator.php', // 'Soyhuce\\ClassmapGenerator\\PhpFileCleaner' => '/code/soyhuce/classmap-generator/src/PhpFileCleaner.php', // 'Soyhuce\\ClassmapGenerator\\Util\\Silencer' => '/code/soyhuce/classmap-generator/src/Util/Silencer.php', // 'Soyhuce\\ClassmapGenerator\\Util\\Filesystem' => '/code/soyhuce/classmap-generator/src/Util/Filesystem.php', // 'Soyhuce\\ClassmapGenerator\\Util\\Platform' => '/code/soyhuce/classmap-generator/src/Util/Platform.php', // 'Soyhuce\\ClassmapGenerator\\Pcre\\Preg' => '/code/soyhuce/classmap-generator/src/Pcre/Preg.php', // 'Soyhuce\\ClassmapGenerator\\Pcre\\PcreException' => '/code/soyhuce/classmap-generator/src/Pcre/PcreException.php', // ]
Installation
You can install the package via composer:
composer require soyhuce/classmap-generator
Usage
\Soyhuce\ClassMapGenerator\ClassMapGenerator::createMap($path);
It will generate the classmap for the given path.
The classmap is identical to the one generated by composer.
Testing
composer test
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
All credit should go to Composer, this package is just an extraction of the ClassmapGenerator class from Composer.
License
The MIT License (MIT). Please see License File for more information.