From fb5deb7d29e15c7cfedacc75edc09e9dfef8ed0c Mon Sep 17 00:00:00 2001 From: marco Date: Mon, 20 Jul 2015 18:10:13 +0200 Subject: [PATCH] Refactoring commands for an easier use. --- README.md | 33 ++++++++++++++++----------------- RoboFile.php | 6 ++++++ composer.lock | 10 +++++----- 3 files changed, 27 insertions(+), 22 deletions(-) diff --git a/README.md b/README.md index fcdcccd7ff..e463f77dc7 100644 --- a/README.md +++ b/README.md @@ -2,28 +2,26 @@ Not another MP2 a.k.a MP3 done the right way. -# Requirements. - -- PHP >=5.3.6 (production). -- PHP >=5.5 (dev). - # Install. -- Clone the repo in wp-content/plugins. - Install system dependencies: -PHP, NodeJS, PhantomJS. +``` +php +nodejs +phantomjs +``` + +- Clone the repo in wp-content/plugins. + - Install composer. ```sh $ curl -sS https://getcomposer.org/installer | php -$ php composer.phar install ``` -- Install PHP dependencies. + +- Install dependencies. ```sh -$ php composer.phar install +$ ./do update ``` -- Instal JS dependencies -```sh -$ npm install # Structure. @@ -51,8 +49,7 @@ Kickstart file. # Unit testing. -Unit tests are in /tests/unit. You can just duplicate a Cest file and start testing. Methods available for testing come from Verify: -https://github.com/Codeception/Verify +- Run tests: ``` $ ./do test:unit ``` @@ -69,5 +66,7 @@ $ ./do test:unit $ ./do tes:acceptance ``` -# Stylus command -stylus -u nib -w assets/css/src/admin.styl -o assets/css/ +# Watch assets. +``` +$ ./do watch +``` diff --git a/RoboFile.php b/RoboFile.php index 0a5dc6b18e..06d24faaa2 100644 --- a/RoboFile.php +++ b/RoboFile.php @@ -1,7 +1,13 @@ _exec('./composer.phar install'); + $this->_exec('npm install'); + } + function update() { $this->_exec('./composer.phar update'); + $this->_exec('npm update'); } function testUnit() { diff --git a/composer.lock b/composer.lock index ed16adb120..425f9c718b 100644 --- a/composer.lock +++ b/composer.lock @@ -653,16 +653,16 @@ }, { "name": "myclabs/deep-copy", - "version": "1.3.0", + "version": "1.3.1", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "96fbdc07635989c35c5a1912379f4c4b2ab15fd5" + "reference": "95d662954e06000cdf63ec9c9f0a6c598d9c5eb9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/96fbdc07635989c35c5a1912379f4c4b2ab15fd5", - "reference": "96fbdc07635989c35c5a1912379f4c4b2ab15fd5", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/95d662954e06000cdf63ec9c9f0a6c598d9c5eb9", + "reference": "95d662954e06000cdf63ec9c9f0a6c598d9c5eb9", "shasum": "" }, "require": { @@ -691,7 +691,7 @@ "object", "object graph" ], - "time": "2015-03-21 22:40:23" + "time": "2015-07-19 19:57:13" }, { "name": "phpdocumentor/reflection-docblock",