diff options
author | diosmosis <benakamoorthi@fastmail.fm> | 2014-09-02 22:07:40 +0400 |
---|---|---|
committer | diosmosis <benakamoorthi@fastmail.fm> | 2014-09-02 22:08:13 +0400 |
commit | 5597c91bb336b4ea0a9dc46abfb9d2adbee233c9 (patch) | |
tree | e97b6f148bc101aa8cb3f0ab3a8ac663788a697c | |
parent | f5fc3c8e62e0a90a6100346cf203d4dc037de22f (diff) |
xhprof removed their composer.json file, adding it to our composer.json file so we can still use composer to manage xhprof. Added an extra script to make sure the update is clean for git users.
-rw-r--r-- | composer.json | 32 | ||||
-rw-r--r-- | composer.lock | 84 | ||||
-rwxr-xr-x | misc/composer/build-xhprof.sh | 3 | ||||
-rwxr-xr-x | misc/composer/clean-xhprof.sh | 12 |
4 files changed, 79 insertions, 52 deletions
diff --git a/composer.json b/composer.json index 6ea410b5fa..be32b796bf 100644 --- a/composer.json +++ b/composer.json @@ -45,11 +45,39 @@ }, "repositories": [ { - "type": "vcs", - "url": "https://github.com/phacility/xhprof" + "type": "package", + "package": { + "name": "facebook/xhprof", + "type": "library", + "description": "XHProf: A Hierarchical Profiler for PHP", + "keywords": ["profiling", "performance"], + "homepage": "http://pecl.php.net/package/xhprof", + "license": "Apache-2.0", + "version": "master", + "require": { + "php": ">=5.2.0" + }, + "autoload": { + "files": [ + "xhprof_lib/utils/xhprof_lib.php", + "xhprof_lib/utils/xhprof_runs.php" + ] + }, + "source": { + "type": "git", + "url": "https://github.com/phacility/xhprof", + "reference": "master" + } + } } ], "scripts": { + "pre-update-cmd": [ + "misc/composer/clean-xhprof.sh" + ], + "pre-install-cmd": [ + "misc/composer/clean-xhprof.sh" + ], "post-update-cmd": [ "misc/composer/build-xhprof.sh" ], diff --git a/composer.lock b/composer.lock index 7ae0681d61..7a30ec861b 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "hash": "1f130896dd9e74174a38115d905d0f32", + "hash": "d04c8063669dd6287714505fbcdc99cc", "packages": [ { "name": "leafo/lessphp", @@ -298,17 +298,11 @@ "packages-dev": [ { "name": "facebook/xhprof", - "version": "dev-master", + "version": "master", "source": { "type": "git", - "url": "https://github.com/phacility/xhprof.git", - "reference": "0a7a5f69f5d762c34056164eb08dd13d41156015" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phacility/xhprof/zipball/0a7a5f69f5d762c34056164eb08dd13d41156015", - "reference": "0a7a5f69f5d762c34056164eb08dd13d41156015", - "shasum": "" + "url": "https://github.com/phacility/xhprof", + "reference": "master" }, "require": { "php": ">=5.2.0" @@ -329,23 +323,20 @@ "performance", "profiling" ], - "support": { - "source": "https://github.com/phacility/xhprof/tree/master" - }, - "time": "2014-04-22 20:02:16" + "time": "2014-08-28 17:34:52" }, { "name": "ocramius/instantiator", - "version": "1.1.2", + "version": "1.1.3", "source": { "type": "git", "url": "https://github.com/Ocramius/Instantiator.git", - "reference": "a7abbb5fc9df6e7126af741dd6c140d1a7369435" + "reference": "e24a12178906ff2e7471b8aaf3a0eb789b59f881" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Ocramius/Instantiator/zipball/a7abbb5fc9df6e7126af741dd6c140d1a7369435", - "reference": "a7abbb5fc9df6e7126af741dd6c140d1a7369435", + "url": "https://api.github.com/repos/Ocramius/Instantiator/zipball/e24a12178906ff2e7471b8aaf3a0eb789b59f881", + "reference": "e24a12178906ff2e7471b8aaf3a0eb789b59f881", "shasum": "" }, "require": { @@ -387,7 +378,7 @@ "constructor", "instantiate" ], - "time": "2014-08-14 15:10:55" + "time": "2014-08-25 14:48:16" }, { "name": "ocramius/lazy-map", @@ -449,29 +440,29 @@ }, { "name": "phpunit/php-code-coverage", - "version": "2.0.10", + "version": "2.0.11", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "6d196af48e8c100a3ae881940123e693da5a9217" + "reference": "53603b3c995f5aab6b59c8e08c3a663d2cc810b7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/6d196af48e8c100a3ae881940123e693da5a9217", - "reference": "6d196af48e8c100a3ae881940123e693da5a9217", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/53603b3c995f5aab6b59c8e08c3a663d2cc810b7", + "reference": "53603b3c995f5aab6b59c8e08c3a663d2cc810b7", "shasum": "" }, "require": { "php": ">=5.3.3", - "phpunit/php-file-iterator": "~1.3.1", - "phpunit/php-text-template": "~1.2.0", - "phpunit/php-token-stream": "~1.2.2", - "sebastian/environment": "~1.0.0", - "sebastian/version": "~1.0.3" + "phpunit/php-file-iterator": "~1.3", + "phpunit/php-text-template": "~1.2", + "phpunit/php-token-stream": "~1.3", + "sebastian/environment": "~1.0", + "sebastian/version": "~1.0" }, "require-dev": { "ext-xdebug": ">=2.1.4", - "phpunit/phpunit": "~4.0.14" + "phpunit/phpunit": "~4.1" }, "suggest": { "ext-dom": "*", @@ -510,7 +501,7 @@ "testing", "xunit" ], - "time": "2014-08-06 06:39:42" + "time": "2014-08-31 06:33:04" }, { "name": "phpunit/php-file-iterator", @@ -647,45 +638,44 @@ }, { "name": "phpunit/php-token-stream", - "version": "1.2.2", + "version": "1.3.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "ad4e1e23ae01b483c16f600ff1bebec184588e32" + "reference": "f8d5d08c56de5cfd592b3340424a81733259a876" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/ad4e1e23ae01b483c16f600ff1bebec184588e32", - "reference": "ad4e1e23ae01b483c16f600ff1bebec184588e32", + "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/f8d5d08c56de5cfd592b3340424a81733259a876", + "reference": "f8d5d08c56de5cfd592b3340424a81733259a876", "shasum": "" }, "require": { "ext-tokenizer": "*", "php": ">=5.3.3" }, + "require-dev": { + "phpunit/phpunit": "~4.2" + }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.2-dev" + "dev-master": "1.3-dev" } }, "autoload": { "classmap": [ - "PHP/" + "src/" ] }, "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "" - ], "license": [ "BSD-3-Clause" ], "authors": [ { "name": "Sebastian Bergmann", - "email": "sb@sebastian-bergmann.de", - "role": "lead" + "email": "sebastian@phpunit.de" } ], "description": "Wrapper around PHP's tokenizer extension.", @@ -693,20 +683,20 @@ "keywords": [ "tokenizer" ], - "time": "2014-03-03 05:10:30" + "time": "2014-08-31 06:12:13" }, { "name": "phpunit/phpunit", - "version": "4.2.2", + "version": "4.2.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "a33fa68ece9f8c68589bfc2da8d2794e27b820bc" + "reference": "f0c2d374ad06ec1e56c721f4ed87c59ff35f440e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/a33fa68ece9f8c68589bfc2da8d2794e27b820bc", - "reference": "a33fa68ece9f8c68589bfc2da8d2794e27b820bc", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/f0c2d374ad06ec1e56c721f4ed87c59ff35f440e", + "reference": "f0c2d374ad06ec1e56c721f4ed87c59ff35f440e", "shasum": "" }, "require": { @@ -767,7 +757,7 @@ "testing", "xunit" ], - "time": "2014-08-18 05:12:30" + "time": "2014-08-31 06:46:49" }, { "name": "phpunit/phpunit-mock-objects", diff --git a/misc/composer/build-xhprof.sh b/misc/composer/build-xhprof.sh index 46637f2bbb..f4a9999678 100755 --- a/misc/composer/build-xhprof.sh +++ b/misc/composer/build-xhprof.sh @@ -6,9 +6,6 @@ cd vendor/facebook/xhprof/extension echo "Building xhprof..." -git fetch origin pull/33/head:33_pull_request -git merge 33_pull_request - echo "Running phpize..." if ! phpize &> ../../../../tmp/xhprof-logs/phpize.log; then echo "Fatal error: phpize failed! View tmp/xhprof-logs/phpize.log for more info." diff --git a/misc/composer/clean-xhprof.sh b/misc/composer/clean-xhprof.sh new file mode 100755 index 0000000000..d20c17dd48 --- /dev/null +++ b/misc/composer/clean-xhprof.sh @@ -0,0 +1,12 @@ +#!/bin/bash + +# if xhprof exists but points to a non-master branch, checkout master so composer won't fail + +if [ -d "vendor/facebook/xhprof/extension" ]; then + cd vendor/facebook/xhprof/extension + + GIT_BRANCH=$(git symbolic-ref HEAD 2>/dev/null) + + git reset --hard &> /dev/null + git checkout master &> /dev/null +fi
\ No newline at end of file |