Moving moontoast/math and symfony/console to require-dev; fixes #20

This commit is contained in:
Ben Ramsey
2014-02-19 19:41:12 -06:00
parent cefaa9aa6c
commit 4fa3a7abfd
3 changed files with 17 additions and 4 deletions
+11
View File
@@ -37,6 +37,17 @@ if (!defined('UUID_COMPOSER_INSTALL')) {
);
}
// We require the Symfony Console component and Moontoast\Math to run
// this command line tool.
if (!class_exists('Symfony\Component\Console\Application') || !class_exists('Moontoast\Math\BigNumber')) {
die(
'To use the uuid command line tool, you need to install symfony/console' . PHP_EOL .
'and moontoast/math. To do so, run the following Composer commands:' . PHP_EOL .
'' . PHP_EOL .
'composer.phar require "moontoast/math=~1.1" "symfony/console=~2.3"' . PHP_EOL
);
}
use Rhumsaa\Uuid\Console\Application;
use Rhumsaa\Uuid\Console\Command;
+5 -3
View File
@@ -20,16 +20,18 @@
"source": "https://github.com/ramsey/uuid"
},
"require": {
"php": ">=5.3.3",
"moontoast/math": "~1.1",
"symfony/console": "~2.4"
"php": ">=5.3.3"
},
"require-dev": {
"moontoast/math": "~1.1",
"symfony/console": "~2.4",
"doctrine/dbal": ">=2.3",
"phpunit/phpunit": "~3.7"
},
"bin": ["bin/uuid"],
"suggest": {
"moontoast/math": "Support for converting UUID to 128-bit integer (in string form).",
"symfony/console": "Support for use of the bin/uuid command line tool.",
"doctrine/dbal": "Allow the use of a UUID as doctrine field type."
},
"autoload": {
+1 -1
View File
@@ -3,7 +3,7 @@
error_reporting(E_ALL | E_STRICT);
// Ensure that composer has installed all dependencies
if (!file_exists(dirname(__DIR__) . DIRECTORY_SEPARATOR . 'composer.lock')) {
if (!file_exists(dirname(__DIR__) . '/vendor/autoload.php')) {
die("Dependencies must be installed using composer:\n\nphp composer.phar install --dev\n\n"
. "See http://getcomposer.org for help with installing composer\n");
}