mirror of
https://github.com/ramsey/uuid.git
synced 2026-06-14 15:56:48 +03:00
32 lines
918 B
PHP
Executable File
32 lines
918 B
PHP
Executable File
#!/usr/bin/env php
|
|
<?php
|
|
/**
|
|
* This file is part of the Rhumsaa\Uuid library
|
|
*
|
|
* For the full copyright and license information, please view the LICENSE
|
|
* file that was distributed with this source code.
|
|
*
|
|
* @copyright Copyright (c) 2013 Ben Ramsey <http://benramsey.com>
|
|
* @license http://opensource.org/licenses/MIT MIT
|
|
*/
|
|
|
|
date_default_timezone_set('UTC');
|
|
|
|
if (PHP_SAPI !== 'cli') {
|
|
echo 'Warning: uuid should be invoked via the CLI version of PHP, not the ' . PHP_SAPI . ' SAPI' . PHP_EOL;
|
|
}
|
|
|
|
if (!file_exists(__DIR__ . '/../vendor/autoload.php')) {
|
|
echo 'You must set up the project dependencies, run the following commands:' . PHP_EOL .
|
|
'curl -sS https://getcomposer.org/installer | php' . PHP_EOL .
|
|
'php composer.phar install' . PHP_EOL;
|
|
exit(1);
|
|
}
|
|
|
|
require __DIR__ . '/../vendor/autoload.php';
|
|
|
|
use Rhumsaa\Uuid\Console\Application;
|
|
|
|
$app = new Application();
|
|
$app->run();
|