├── .gitignore ├── .travis.yml ├── README.md ├── bin └── pdpkg ├── composer.json ├── composer.lock ├── eg.yml ├── phpspec.yml ├── spec ├── DescriberSpec.php └── KeyFilterSpec.php ├── src ├── Describer.php ├── KeyFilter.php └── PackageCommand.php └── tests ├── DescriberTest.php └── YmlParserTest.php /.gitignore: -------------------------------------------------------------------------------- 1 | vendor 2 | *.phar 3 | tags 4 | build 5 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | language: php 2 | php: 3 | - 5.6 4 | - 5.5 5 | - 5.4 6 | 7 | install: 8 | - composer update 9 | - composer install 10 | 11 | script: 12 | - vendor/bin/phpspec run -fpretty 13 | - vendor/bin/phpunit tests 14 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Describe your Deb packages 2 | 3 | Just a simple wrapper around the package 4 | [`wdalmut/php-deb-packager`](https://github.com/wdalmut/php-deb-packager) 5 | 6 | * master [![Build Status](https://travis-ci.org/wdalmut/php-deb-describe.svg?branch=master)](https://travis-ci.org/wdalmut/php-deb-describe) 7 | 8 | ## Describe a `deb` package with Yaml files 9 | 10 | ```yml 11 | output_path: /mnt/out 12 | mount: 13 | - {src: "/first", dest: "/somewhere"} 14 | - {src: "/src", dest: "/usr/shara/mysw"} 15 | control: 16 | package: my-package-name 17 | version: 0.0.1 18 | depends: php5, php5-cli, php5-curl 19 | maintainer: Walter Dal Mut [an-email@email.tld] 20 | provides: something, something-else 21 | replaces: first-package, second-package 22 | suggests: php5-mcrypt, php5-xsl 23 | pre_depends: build-essentials, libc6 24 | architecture: all 25 | section: web 26 | ``` 27 | 28 | ## Use with composer 29 | 30 | Just require it! 31 | 32 | ``` 33 | composer require wdalmut/php-deb-describe:dev-master 34 | ``` 35 | 36 | And use it! 37 | 38 | ``` 39 | ./vendor/bin/pdpkg package your.yml 40 | ``` 41 | 42 | ## Use it as `phar` package 43 | 44 | You can create your `phar` package with [clue/phar-composer](https://github.com/clue/phar-composer) 45 | 46 | ```sh 47 | phar-composer.phar build wdalmut/php-deb-describe:dev-master 48 | ``` 49 | 50 | ## Use the library directly 51 | 52 | Just prepare a simple `compile.php` file 53 | 54 | ```php 55 | setControl(new StandardFile()); 63 | 64 | $describer = new Describer($parser, $packager); 65 | echo $describer->compose(file_get_contents("/path/to/file.yml")); 66 | ``` 67 | 68 | And run it! 69 | 70 | ```sh 71 | $(php compile.php) 72 | ``` 73 | 74 | Now you have your `.deb` package! 75 | -------------------------------------------------------------------------------- /bin/pdpkg: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env php 2 | add(new PackageCommand()); 17 | $application->run(); 18 | -------------------------------------------------------------------------------- /composer.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "wdalmut/php-deb-describe", 3 | "description": "A simple debian packager wrapper for PHP applications", 4 | "type":"library", 5 | "keywords":["deb","packager","ubuntu","php-deb", "debian", "yml"], 6 | "license":"MIT", 7 | "authors": [ 8 | { 9 | "name":"Walter Dal Mut", 10 | "email":"walter.dalmut@gmail.com", 11 | "homepage":"http://walterdalmut.com", 12 | "role":"Developer" 13 | } 14 | ], 15 | "support": { 16 | "email":"walter.dalmut@gmail.com" 17 | }, 18 | "require": { 19 | "symfony/yaml": "~2.6", 20 | "wdalmut/php-deb-packager": ">=0.0.10", 21 | "symfony/console": "~2.6" 22 | }, 23 | "require-dev": { 24 | "phpunit/phpunit": "~4", 25 | "phpspec/phpspec": "~2", 26 | "mikey179/vfsStream": "1.4.*" 27 | }, 28 | "autoload": { 29 | "psr-4": { 30 | "Corley\\Deb\\Describe\\": "src/" 31 | } 32 | }, 33 | "autoload-dev": { 34 | "psr-4": { 35 | "Corley\\Deb\\Describe\\": "tests/" 36 | } 37 | }, 38 | "bin": ["bin/pdpkg"] 39 | } 40 | -------------------------------------------------------------------------------- /composer.lock: -------------------------------------------------------------------------------- 1 | { 2 | "_readme": [ 3 | "This file locks the dependencies of your project to a known state", 4 | "Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", 5 | "This file is @generated automatically" 6 | ], 7 | "hash": "bcbb5ab686fcb9d35be1d235c826b74f", 8 | "packages": [ 9 | { 10 | "name": "symfony/console", 11 | "version": "v2.6.6", 12 | "target-dir": "Symfony/Component/Console", 13 | "source": { 14 | "type": "git", 15 | "url": "https://github.com/symfony/Console.git", 16 | "reference": "5b91dc4ed5eb08553f57f6df04c4730a73992667" 17 | }, 18 | "dist": { 19 | "type": "zip", 20 | "url": "https://api.github.com/repos/symfony/Console/zipball/5b91dc4ed5eb08553f57f6df04c4730a73992667", 21 | "reference": "5b91dc4ed5eb08553f57f6df04c4730a73992667", 22 | "shasum": "" 23 | }, 24 | "require": { 25 | "php": ">=5.3.3" 26 | }, 27 | "require-dev": { 28 | "psr/log": "~1.0", 29 | "symfony/event-dispatcher": "~2.1", 30 | "symfony/phpunit-bridge": "~2.7", 31 | "symfony/process": "~2.1" 32 | }, 33 | "suggest": { 34 | "psr/log": "For using the console logger", 35 | "symfony/event-dispatcher": "", 36 | "symfony/process": "" 37 | }, 38 | "type": "library", 39 | "extra": { 40 | "branch-alias": { 41 | "dev-master": "2.6-dev" 42 | } 43 | }, 44 | "autoload": { 45 | "psr-0": { 46 | "Symfony\\Component\\Console\\": "" 47 | } 48 | }, 49 | "notification-url": "https://packagist.org/downloads/", 50 | "license": [ 51 | "MIT" 52 | ], 53 | "authors": [ 54 | { 55 | "name": "Symfony Community", 56 | "homepage": "http://symfony.com/contributors" 57 | }, 58 | { 59 | "name": "Fabien Potencier", 60 | "email": "fabien@symfony.com" 61 | } 62 | ], 63 | "description": "Symfony Console Component", 64 | "homepage": "http://symfony.com", 65 | "time": "2015-03-30 15:54:10" 66 | }, 67 | { 68 | "name": "symfony/yaml", 69 | "version": "v2.6.6", 70 | "target-dir": "Symfony/Component/Yaml", 71 | "source": { 72 | "type": "git", 73 | "url": "https://github.com/symfony/Yaml.git", 74 | "reference": "174f009ed36379a801109955fc5a71a49fe62dd4" 75 | }, 76 | "dist": { 77 | "type": "zip", 78 | "url": "https://api.github.com/repos/symfony/Yaml/zipball/174f009ed36379a801109955fc5a71a49fe62dd4", 79 | "reference": "174f009ed36379a801109955fc5a71a49fe62dd4", 80 | "shasum": "" 81 | }, 82 | "require": { 83 | "php": ">=5.3.3" 84 | }, 85 | "require-dev": { 86 | "symfony/phpunit-bridge": "~2.7" 87 | }, 88 | "type": "library", 89 | "extra": { 90 | "branch-alias": { 91 | "dev-master": "2.6-dev" 92 | } 93 | }, 94 | "autoload": { 95 | "psr-0": { 96 | "Symfony\\Component\\Yaml\\": "" 97 | } 98 | }, 99 | "notification-url": "https://packagist.org/downloads/", 100 | "license": [ 101 | "MIT" 102 | ], 103 | "authors": [ 104 | { 105 | "name": "Symfony Community", 106 | "homepage": "http://symfony.com/contributors" 107 | }, 108 | { 109 | "name": "Fabien Potencier", 110 | "email": "fabien@symfony.com" 111 | } 112 | ], 113 | "description": "Symfony Yaml Component", 114 | "homepage": "http://symfony.com", 115 | "time": "2015-03-30 15:54:10" 116 | }, 117 | { 118 | "name": "wdalmut/php-deb-packager", 119 | "version": "0.0.10", 120 | "source": { 121 | "type": "git", 122 | "url": "https://github.com/wdalmut/php-deb-packager.git", 123 | "reference": "29a2ed1d4667f000916ea9c0c5d126cf4c68755d" 124 | }, 125 | "dist": { 126 | "type": "zip", 127 | "url": "https://api.github.com/repos/wdalmut/php-deb-packager/zipball/29a2ed1d4667f000916ea9c0c5d126cf4c68755d", 128 | "reference": "29a2ed1d4667f000916ea9c0c5d126cf4c68755d", 129 | "shasum": "" 130 | }, 131 | "require": { 132 | "php": ">=5.3.3" 133 | }, 134 | "require-dev": { 135 | "phpunit/phpunit": "~4" 136 | }, 137 | "type": "library", 138 | "autoload": { 139 | "psr-0": { 140 | "wdm": [ 141 | "src/", 142 | "tests/" 143 | ] 144 | } 145 | }, 146 | "notification-url": "https://packagist.org/downloads/", 147 | "license": [ 148 | "MIT" 149 | ], 150 | "authors": [ 151 | { 152 | "name": "Walter Dal Mut", 153 | "email": "walter.dalmut@gmail.com", 154 | "homepage": "http://walterdalmut.com", 155 | "role": "Developer" 156 | } 157 | ], 158 | "description": "A simple debian packager for PHP applications", 159 | "keywords": [ 160 | "deb", 161 | "debian", 162 | "packager", 163 | "php-deb", 164 | "ubuntu" 165 | ], 166 | "time": "2015-04-12 11:13:24" 167 | } 168 | ], 169 | "packages-dev": [ 170 | { 171 | "name": "doctrine/instantiator", 172 | "version": "1.0.4", 173 | "source": { 174 | "type": "git", 175 | "url": "https://github.com/doctrine/instantiator.git", 176 | "reference": "f976e5de371104877ebc89bd8fecb0019ed9c119" 177 | }, 178 | "dist": { 179 | "type": "zip", 180 | "url": "https://api.github.com/repos/doctrine/instantiator/zipball/f976e5de371104877ebc89bd8fecb0019ed9c119", 181 | "reference": "f976e5de371104877ebc89bd8fecb0019ed9c119", 182 | "shasum": "" 183 | }, 184 | "require": { 185 | "php": ">=5.3,<8.0-DEV" 186 | }, 187 | "require-dev": { 188 | "athletic/athletic": "~0.1.8", 189 | "ext-pdo": "*", 190 | "ext-phar": "*", 191 | "phpunit/phpunit": "~4.0", 192 | "squizlabs/php_codesniffer": "2.0.*@ALPHA" 193 | }, 194 | "type": "library", 195 | "extra": { 196 | "branch-alias": { 197 | "dev-master": "1.0.x-dev" 198 | } 199 | }, 200 | "autoload": { 201 | "psr-0": { 202 | "Doctrine\\Instantiator\\": "src" 203 | } 204 | }, 205 | "notification-url": "https://packagist.org/downloads/", 206 | "license": [ 207 | "MIT" 208 | ], 209 | "authors": [ 210 | { 211 | "name": "Marco Pivetta", 212 | "email": "ocramius@gmail.com", 213 | "homepage": "http://ocramius.github.com/" 214 | } 215 | ], 216 | "description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors", 217 | "homepage": "https://github.com/doctrine/instantiator", 218 | "keywords": [ 219 | "constructor", 220 | "instantiate" 221 | ], 222 | "time": "2014-10-13 12:58:55" 223 | }, 224 | { 225 | "name": "mikey179/vfsStream", 226 | "version": "v1.4.0", 227 | "source": { 228 | "type": "git", 229 | "url": "https://github.com/mikey179/vfsStream.git", 230 | "reference": "61b12172292cf539685507aa65b076c1530e83c1" 231 | }, 232 | "dist": { 233 | "type": "zip", 234 | "url": "https://api.github.com/repos/mikey179/vfsStream/zipball/61b12172292cf539685507aa65b076c1530e83c1", 235 | "reference": "61b12172292cf539685507aa65b076c1530e83c1", 236 | "shasum": "" 237 | }, 238 | "require": { 239 | "php": ">=5.3.0" 240 | }, 241 | "require-dev": { 242 | "phpunit/phpunit": "~4.2" 243 | }, 244 | "type": "library", 245 | "extra": { 246 | "branch-alias": { 247 | "dev-master": "1.4.x-dev" 248 | } 249 | }, 250 | "autoload": { 251 | "psr-0": { 252 | "org\\bovigo\\vfs\\": "src/main/php" 253 | } 254 | }, 255 | "notification-url": "https://packagist.org/downloads/", 256 | "license": [ 257 | "BSD" 258 | ], 259 | "homepage": "http://vfs.bovigo.org/", 260 | "time": "2014-09-14 10:18:53" 261 | }, 262 | { 263 | "name": "phpdocumentor/reflection-docblock", 264 | "version": "2.0.4", 265 | "source": { 266 | "type": "git", 267 | "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", 268 | "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8" 269 | }, 270 | "dist": { 271 | "type": "zip", 272 | "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/d68dbdc53dc358a816f00b300704702b2eaff7b8", 273 | "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8", 274 | "shasum": "" 275 | }, 276 | "require": { 277 | "php": ">=5.3.3" 278 | }, 279 | "require-dev": { 280 | "phpunit/phpunit": "~4.0" 281 | }, 282 | "suggest": { 283 | "dflydev/markdown": "~1.0", 284 | "erusev/parsedown": "~1.0" 285 | }, 286 | "type": "library", 287 | "extra": { 288 | "branch-alias": { 289 | "dev-master": "2.0.x-dev" 290 | } 291 | }, 292 | "autoload": { 293 | "psr-0": { 294 | "phpDocumentor": [ 295 | "src/" 296 | ] 297 | } 298 | }, 299 | "notification-url": "https://packagist.org/downloads/", 300 | "license": [ 301 | "MIT" 302 | ], 303 | "authors": [ 304 | { 305 | "name": "Mike van Riel", 306 | "email": "mike.vanriel@naenius.com" 307 | } 308 | ], 309 | "time": "2015-02-03 12:10:50" 310 | }, 311 | { 312 | "name": "phpspec/php-diff", 313 | "version": "v1.0.2", 314 | "source": { 315 | "type": "git", 316 | "url": "https://github.com/phpspec/php-diff.git", 317 | "reference": "30e103d19519fe678ae64a60d77884ef3d71b28a" 318 | }, 319 | "dist": { 320 | "type": "zip", 321 | "url": "https://api.github.com/repos/phpspec/php-diff/zipball/30e103d19519fe678ae64a60d77884ef3d71b28a", 322 | "reference": "30e103d19519fe678ae64a60d77884ef3d71b28a", 323 | "shasum": "" 324 | }, 325 | "type": "library", 326 | "autoload": { 327 | "psr-0": { 328 | "Diff": "lib/" 329 | } 330 | }, 331 | "notification-url": "https://packagist.org/downloads/", 332 | "license": [ 333 | "BSD-3-Clause" 334 | ], 335 | "authors": [ 336 | { 337 | "name": "Chris Boulton", 338 | "homepage": "http://github.com/chrisboulton", 339 | "role": "Original developer" 340 | } 341 | ], 342 | "description": "A comprehensive library for generating differences between two hashable objects (strings or arrays).", 343 | "time": "2013-11-01 13:02:21" 344 | }, 345 | { 346 | "name": "phpspec/phpspec", 347 | "version": "2.1.1", 348 | "source": { 349 | "type": "git", 350 | "url": "https://github.com/phpspec/phpspec.git", 351 | "reference": "66a1df93099282b1514e9e001fcf6e9393f7783d" 352 | }, 353 | "dist": { 354 | "type": "zip", 355 | "url": "https://api.github.com/repos/phpspec/phpspec/zipball/66a1df93099282b1514e9e001fcf6e9393f7783d", 356 | "reference": "66a1df93099282b1514e9e001fcf6e9393f7783d", 357 | "shasum": "" 358 | }, 359 | "require": { 360 | "doctrine/instantiator": "~1.0,>=1.0.1", 361 | "php": ">=5.3.3", 362 | "phpspec/php-diff": "~1.0.0", 363 | "phpspec/prophecy": "~1.1", 364 | "sebastian/exporter": "~1.0", 365 | "symfony/console": "~2.3", 366 | "symfony/event-dispatcher": "~2.1", 367 | "symfony/finder": "~2.1", 368 | "symfony/process": "~2.1", 369 | "symfony/yaml": "~2.1" 370 | }, 371 | "require-dev": { 372 | "behat/behat": "~3.0,>=3.0.11", 373 | "bossa/phpspec2-expect": "~1.0", 374 | "symfony/filesystem": "~2.1" 375 | }, 376 | "suggest": { 377 | "phpspec/nyan-formatters": "~1.0 – Adds Nyan formatters" 378 | }, 379 | "bin": [ 380 | "bin/phpspec" 381 | ], 382 | "type": "library", 383 | "extra": { 384 | "branch-alias": { 385 | "dev-master": "2.1.x-dev" 386 | } 387 | }, 388 | "autoload": { 389 | "psr-0": { 390 | "PhpSpec": "src/" 391 | } 392 | }, 393 | "notification-url": "https://packagist.org/downloads/", 394 | "license": [ 395 | "MIT" 396 | ], 397 | "authors": [ 398 | { 399 | "name": "Konstantin Kudryashov", 400 | "email": "ever.zet@gmail.com", 401 | "homepage": "http://everzet.com" 402 | }, 403 | { 404 | "name": "Marcello Duarte", 405 | "homepage": "http://marcelloduarte.net/" 406 | } 407 | ], 408 | "description": "Specification-oriented BDD framework for PHP 5.3+", 409 | "homepage": "http://phpspec.net/", 410 | "keywords": [ 411 | "BDD", 412 | "SpecBDD", 413 | "TDD", 414 | "spec", 415 | "specification", 416 | "testing", 417 | "tests" 418 | ], 419 | "time": "2015-01-09 13:21:45" 420 | }, 421 | { 422 | "name": "phpspec/prophecy", 423 | "version": "1.4.0", 424 | "source": { 425 | "type": "git", 426 | "url": "https://github.com/phpspec/prophecy.git", 427 | "reference": "8724cd239f8ef4c046f55a3b18b4d91cc7f3e4c5" 428 | }, 429 | "dist": { 430 | "type": "zip", 431 | "url": "https://api.github.com/repos/phpspec/prophecy/zipball/8724cd239f8ef4c046f55a3b18b4d91cc7f3e4c5", 432 | "reference": "8724cd239f8ef4c046f55a3b18b4d91cc7f3e4c5", 433 | "shasum": "" 434 | }, 435 | "require": { 436 | "doctrine/instantiator": "^1.0.2", 437 | "phpdocumentor/reflection-docblock": "~2.0", 438 | "sebastian/comparator": "~1.1" 439 | }, 440 | "require-dev": { 441 | "phpspec/phpspec": "~2.0" 442 | }, 443 | "type": "library", 444 | "extra": { 445 | "branch-alias": { 446 | "dev-master": "1.4.x-dev" 447 | } 448 | }, 449 | "autoload": { 450 | "psr-0": { 451 | "Prophecy\\": "src/" 452 | } 453 | }, 454 | "notification-url": "https://packagist.org/downloads/", 455 | "license": [ 456 | "MIT" 457 | ], 458 | "authors": [ 459 | { 460 | "name": "Konstantin Kudryashov", 461 | "email": "ever.zet@gmail.com", 462 | "homepage": "http://everzet.com" 463 | }, 464 | { 465 | "name": "Marcello Duarte", 466 | "email": "marcello.duarte@gmail.com" 467 | } 468 | ], 469 | "description": "Highly opinionated mocking framework for PHP 5.3+", 470 | "homepage": "https://github.com/phpspec/prophecy", 471 | "keywords": [ 472 | "Double", 473 | "Dummy", 474 | "fake", 475 | "mock", 476 | "spy", 477 | "stub" 478 | ], 479 | "time": "2015-03-27 19:31:25" 480 | }, 481 | { 482 | "name": "phpunit/php-code-coverage", 483 | "version": "2.0.16", 484 | "source": { 485 | "type": "git", 486 | "url": "https://github.com/sebastianbergmann/php-code-coverage.git", 487 | "reference": "934fd03eb6840508231a7f73eb8940cf32c3b66c" 488 | }, 489 | "dist": { 490 | "type": "zip", 491 | "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/934fd03eb6840508231a7f73eb8940cf32c3b66c", 492 | "reference": "934fd03eb6840508231a7f73eb8940cf32c3b66c", 493 | "shasum": "" 494 | }, 495 | "require": { 496 | "php": ">=5.3.3", 497 | "phpunit/php-file-iterator": "~1.3", 498 | "phpunit/php-text-template": "~1.2", 499 | "phpunit/php-token-stream": "~1.3", 500 | "sebastian/environment": "~1.0", 501 | "sebastian/version": "~1.0" 502 | }, 503 | "require-dev": { 504 | "ext-xdebug": ">=2.1.4", 505 | "phpunit/phpunit": "~4" 506 | }, 507 | "suggest": { 508 | "ext-dom": "*", 509 | "ext-xdebug": ">=2.2.1", 510 | "ext-xmlwriter": "*" 511 | }, 512 | "type": "library", 513 | "extra": { 514 | "branch-alias": { 515 | "dev-master": "2.0.x-dev" 516 | } 517 | }, 518 | "autoload": { 519 | "classmap": [ 520 | "src/" 521 | ] 522 | }, 523 | "notification-url": "https://packagist.org/downloads/", 524 | "license": [ 525 | "BSD-3-Clause" 526 | ], 527 | "authors": [ 528 | { 529 | "name": "Sebastian Bergmann", 530 | "email": "sb@sebastian-bergmann.de", 531 | "role": "lead" 532 | } 533 | ], 534 | "description": "Library that provides collection, processing, and rendering functionality for PHP code coverage information.", 535 | "homepage": "https://github.com/sebastianbergmann/php-code-coverage", 536 | "keywords": [ 537 | "coverage", 538 | "testing", 539 | "xunit" 540 | ], 541 | "time": "2015-04-11 04:35:00" 542 | }, 543 | { 544 | "name": "phpunit/php-file-iterator", 545 | "version": "1.4.0", 546 | "source": { 547 | "type": "git", 548 | "url": "https://github.com/sebastianbergmann/php-file-iterator.git", 549 | "reference": "a923bb15680d0089e2316f7a4af8f437046e96bb" 550 | }, 551 | "dist": { 552 | "type": "zip", 553 | "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/a923bb15680d0089e2316f7a4af8f437046e96bb", 554 | "reference": "a923bb15680d0089e2316f7a4af8f437046e96bb", 555 | "shasum": "" 556 | }, 557 | "require": { 558 | "php": ">=5.3.3" 559 | }, 560 | "type": "library", 561 | "extra": { 562 | "branch-alias": { 563 | "dev-master": "1.4.x-dev" 564 | } 565 | }, 566 | "autoload": { 567 | "classmap": [ 568 | "src/" 569 | ] 570 | }, 571 | "notification-url": "https://packagist.org/downloads/", 572 | "license": [ 573 | "BSD-3-Clause" 574 | ], 575 | "authors": [ 576 | { 577 | "name": "Sebastian Bergmann", 578 | "email": "sb@sebastian-bergmann.de", 579 | "role": "lead" 580 | } 581 | ], 582 | "description": "FilterIterator implementation that filters files based on a list of suffixes.", 583 | "homepage": "https://github.com/sebastianbergmann/php-file-iterator/", 584 | "keywords": [ 585 | "filesystem", 586 | "iterator" 587 | ], 588 | "time": "2015-04-02 05:19:05" 589 | }, 590 | { 591 | "name": "phpunit/php-text-template", 592 | "version": "1.2.0", 593 | "source": { 594 | "type": "git", 595 | "url": "https://github.com/sebastianbergmann/php-text-template.git", 596 | "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a" 597 | }, 598 | "dist": { 599 | "type": "zip", 600 | "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/206dfefc0ffe9cebf65c413e3d0e809c82fbf00a", 601 | "reference": "206dfefc0ffe9cebf65c413e3d0e809c82fbf00a", 602 | "shasum": "" 603 | }, 604 | "require": { 605 | "php": ">=5.3.3" 606 | }, 607 | "type": "library", 608 | "autoload": { 609 | "classmap": [ 610 | "Text/" 611 | ] 612 | }, 613 | "notification-url": "https://packagist.org/downloads/", 614 | "include-path": [ 615 | "" 616 | ], 617 | "license": [ 618 | "BSD-3-Clause" 619 | ], 620 | "authors": [ 621 | { 622 | "name": "Sebastian Bergmann", 623 | "email": "sb@sebastian-bergmann.de", 624 | "role": "lead" 625 | } 626 | ], 627 | "description": "Simple template engine.", 628 | "homepage": "https://github.com/sebastianbergmann/php-text-template/", 629 | "keywords": [ 630 | "template" 631 | ], 632 | "time": "2014-01-30 17:20:04" 633 | }, 634 | { 635 | "name": "phpunit/php-timer", 636 | "version": "1.0.5", 637 | "source": { 638 | "type": "git", 639 | "url": "https://github.com/sebastianbergmann/php-timer.git", 640 | "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c" 641 | }, 642 | "dist": { 643 | "type": "zip", 644 | "url": "https://api.github.com/repos/sebastianbergmann/php-timer/zipball/19689d4354b295ee3d8c54b4f42c3efb69cbc17c", 645 | "reference": "19689d4354b295ee3d8c54b4f42c3efb69cbc17c", 646 | "shasum": "" 647 | }, 648 | "require": { 649 | "php": ">=5.3.3" 650 | }, 651 | "type": "library", 652 | "autoload": { 653 | "classmap": [ 654 | "PHP/" 655 | ] 656 | }, 657 | "notification-url": "https://packagist.org/downloads/", 658 | "include-path": [ 659 | "" 660 | ], 661 | "license": [ 662 | "BSD-3-Clause" 663 | ], 664 | "authors": [ 665 | { 666 | "name": "Sebastian Bergmann", 667 | "email": "sb@sebastian-bergmann.de", 668 | "role": "lead" 669 | } 670 | ], 671 | "description": "Utility class for timing", 672 | "homepage": "https://github.com/sebastianbergmann/php-timer/", 673 | "keywords": [ 674 | "timer" 675 | ], 676 | "time": "2013-08-02 07:42:54" 677 | }, 678 | { 679 | "name": "phpunit/php-token-stream", 680 | "version": "1.4.1", 681 | "source": { 682 | "type": "git", 683 | "url": "https://github.com/sebastianbergmann/php-token-stream.git", 684 | "reference": "eab81d02569310739373308137284e0158424330" 685 | }, 686 | "dist": { 687 | "type": "zip", 688 | "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/eab81d02569310739373308137284e0158424330", 689 | "reference": "eab81d02569310739373308137284e0158424330", 690 | "shasum": "" 691 | }, 692 | "require": { 693 | "ext-tokenizer": "*", 694 | "php": ">=5.3.3" 695 | }, 696 | "require-dev": { 697 | "phpunit/phpunit": "~4.2" 698 | }, 699 | "type": "library", 700 | "extra": { 701 | "branch-alias": { 702 | "dev-master": "1.4-dev" 703 | } 704 | }, 705 | "autoload": { 706 | "classmap": [ 707 | "src/" 708 | ] 709 | }, 710 | "notification-url": "https://packagist.org/downloads/", 711 | "license": [ 712 | "BSD-3-Clause" 713 | ], 714 | "authors": [ 715 | { 716 | "name": "Sebastian Bergmann", 717 | "email": "sebastian@phpunit.de" 718 | } 719 | ], 720 | "description": "Wrapper around PHP's tokenizer extension.", 721 | "homepage": "https://github.com/sebastianbergmann/php-token-stream/", 722 | "keywords": [ 723 | "tokenizer" 724 | ], 725 | "time": "2015-04-08 04:46:07" 726 | }, 727 | { 728 | "name": "phpunit/phpunit", 729 | "version": "4.6.4", 730 | "source": { 731 | "type": "git", 732 | "url": "https://github.com/sebastianbergmann/phpunit.git", 733 | "reference": "163232991e652e6efed2f8470326fffa61e848e2" 734 | }, 735 | "dist": { 736 | "type": "zip", 737 | "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/163232991e652e6efed2f8470326fffa61e848e2", 738 | "reference": "163232991e652e6efed2f8470326fffa61e848e2", 739 | "shasum": "" 740 | }, 741 | "require": { 742 | "ext-dom": "*", 743 | "ext-json": "*", 744 | "ext-pcre": "*", 745 | "ext-reflection": "*", 746 | "ext-spl": "*", 747 | "php": ">=5.3.3", 748 | "phpspec/prophecy": "~1.3,>=1.3.1", 749 | "phpunit/php-code-coverage": "~2.0,>=2.0.11", 750 | "phpunit/php-file-iterator": "~1.4", 751 | "phpunit/php-text-template": "~1.2", 752 | "phpunit/php-timer": "~1.0", 753 | "phpunit/phpunit-mock-objects": "~2.3", 754 | "sebastian/comparator": "~1.1", 755 | "sebastian/diff": "~1.2", 756 | "sebastian/environment": "~1.2", 757 | "sebastian/exporter": "~1.2", 758 | "sebastian/global-state": "~1.0", 759 | "sebastian/version": "~1.0", 760 | "symfony/yaml": "~2.1|~3.0" 761 | }, 762 | "suggest": { 763 | "phpunit/php-invoker": "~1.1" 764 | }, 765 | "bin": [ 766 | "phpunit" 767 | ], 768 | "type": "library", 769 | "extra": { 770 | "branch-alias": { 771 | "dev-master": "4.6.x-dev" 772 | } 773 | }, 774 | "autoload": { 775 | "classmap": [ 776 | "src/" 777 | ] 778 | }, 779 | "notification-url": "https://packagist.org/downloads/", 780 | "license": [ 781 | "BSD-3-Clause" 782 | ], 783 | "authors": [ 784 | { 785 | "name": "Sebastian Bergmann", 786 | "email": "sebastian@phpunit.de", 787 | "role": "lead" 788 | } 789 | ], 790 | "description": "The PHP Unit Testing framework.", 791 | "homepage": "https://phpunit.de/", 792 | "keywords": [ 793 | "phpunit", 794 | "testing", 795 | "xunit" 796 | ], 797 | "time": "2015-04-11 05:23:21" 798 | }, 799 | { 800 | "name": "phpunit/phpunit-mock-objects", 801 | "version": "2.3.1", 802 | "source": { 803 | "type": "git", 804 | "url": "https://github.com/sebastianbergmann/phpunit-mock-objects.git", 805 | "reference": "74ffb87f527f24616f72460e54b595f508dccb5c" 806 | }, 807 | "dist": { 808 | "type": "zip", 809 | "url": "https://api.github.com/repos/sebastianbergmann/phpunit-mock-objects/zipball/74ffb87f527f24616f72460e54b595f508dccb5c", 810 | "reference": "74ffb87f527f24616f72460e54b595f508dccb5c", 811 | "shasum": "" 812 | }, 813 | "require": { 814 | "doctrine/instantiator": "~1.0,>=1.0.2", 815 | "php": ">=5.3.3", 816 | "phpunit/php-text-template": "~1.2" 817 | }, 818 | "require-dev": { 819 | "phpunit/phpunit": "~4.4" 820 | }, 821 | "suggest": { 822 | "ext-soap": "*" 823 | }, 824 | "type": "library", 825 | "extra": { 826 | "branch-alias": { 827 | "dev-master": "2.3.x-dev" 828 | } 829 | }, 830 | "autoload": { 831 | "classmap": [ 832 | "src/" 833 | ] 834 | }, 835 | "notification-url": "https://packagist.org/downloads/", 836 | "license": [ 837 | "BSD-3-Clause" 838 | ], 839 | "authors": [ 840 | { 841 | "name": "Sebastian Bergmann", 842 | "email": "sb@sebastian-bergmann.de", 843 | "role": "lead" 844 | } 845 | ], 846 | "description": "Mock Object library for PHPUnit", 847 | "homepage": "https://github.com/sebastianbergmann/phpunit-mock-objects/", 848 | "keywords": [ 849 | "mock", 850 | "xunit" 851 | ], 852 | "time": "2015-04-02 05:36:41" 853 | }, 854 | { 855 | "name": "sebastian/comparator", 856 | "version": "1.1.1", 857 | "source": { 858 | "type": "git", 859 | "url": "https://github.com/sebastianbergmann/comparator.git", 860 | "reference": "1dd8869519a225f7f2b9eb663e225298fade819e" 861 | }, 862 | "dist": { 863 | "type": "zip", 864 | "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/1dd8869519a225f7f2b9eb663e225298fade819e", 865 | "reference": "1dd8869519a225f7f2b9eb663e225298fade819e", 866 | "shasum": "" 867 | }, 868 | "require": { 869 | "php": ">=5.3.3", 870 | "sebastian/diff": "~1.2", 871 | "sebastian/exporter": "~1.2" 872 | }, 873 | "require-dev": { 874 | "phpunit/phpunit": "~4.4" 875 | }, 876 | "type": "library", 877 | "extra": { 878 | "branch-alias": { 879 | "dev-master": "1.1.x-dev" 880 | } 881 | }, 882 | "autoload": { 883 | "classmap": [ 884 | "src/" 885 | ] 886 | }, 887 | "notification-url": "https://packagist.org/downloads/", 888 | "license": [ 889 | "BSD-3-Clause" 890 | ], 891 | "authors": [ 892 | { 893 | "name": "Jeff Welch", 894 | "email": "whatthejeff@gmail.com" 895 | }, 896 | { 897 | "name": "Volker Dusch", 898 | "email": "github@wallbash.com" 899 | }, 900 | { 901 | "name": "Bernhard Schussek", 902 | "email": "bschussek@2bepublished.at" 903 | }, 904 | { 905 | "name": "Sebastian Bergmann", 906 | "email": "sebastian@phpunit.de" 907 | } 908 | ], 909 | "description": "Provides the functionality to compare PHP values for equality", 910 | "homepage": "http://www.github.com/sebastianbergmann/comparator", 911 | "keywords": [ 912 | "comparator", 913 | "compare", 914 | "equality" 915 | ], 916 | "time": "2015-01-29 16:28:08" 917 | }, 918 | { 919 | "name": "sebastian/diff", 920 | "version": "1.3.0", 921 | "source": { 922 | "type": "git", 923 | "url": "https://github.com/sebastianbergmann/diff.git", 924 | "reference": "863df9687835c62aa423a22412d26fa2ebde3fd3" 925 | }, 926 | "dist": { 927 | "type": "zip", 928 | "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/863df9687835c62aa423a22412d26fa2ebde3fd3", 929 | "reference": "863df9687835c62aa423a22412d26fa2ebde3fd3", 930 | "shasum": "" 931 | }, 932 | "require": { 933 | "php": ">=5.3.3" 934 | }, 935 | "require-dev": { 936 | "phpunit/phpunit": "~4.2" 937 | }, 938 | "type": "library", 939 | "extra": { 940 | "branch-alias": { 941 | "dev-master": "1.3-dev" 942 | } 943 | }, 944 | "autoload": { 945 | "classmap": [ 946 | "src/" 947 | ] 948 | }, 949 | "notification-url": "https://packagist.org/downloads/", 950 | "license": [ 951 | "BSD-3-Clause" 952 | ], 953 | "authors": [ 954 | { 955 | "name": "Kore Nordmann", 956 | "email": "mail@kore-nordmann.de" 957 | }, 958 | { 959 | "name": "Sebastian Bergmann", 960 | "email": "sebastian@phpunit.de" 961 | } 962 | ], 963 | "description": "Diff implementation", 964 | "homepage": "http://www.github.com/sebastianbergmann/diff", 965 | "keywords": [ 966 | "diff" 967 | ], 968 | "time": "2015-02-22 15:13:53" 969 | }, 970 | { 971 | "name": "sebastian/environment", 972 | "version": "1.2.2", 973 | "source": { 974 | "type": "git", 975 | "url": "https://github.com/sebastianbergmann/environment.git", 976 | "reference": "5a8c7d31914337b69923db26c4221b81ff5a196e" 977 | }, 978 | "dist": { 979 | "type": "zip", 980 | "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/5a8c7d31914337b69923db26c4221b81ff5a196e", 981 | "reference": "5a8c7d31914337b69923db26c4221b81ff5a196e", 982 | "shasum": "" 983 | }, 984 | "require": { 985 | "php": ">=5.3.3" 986 | }, 987 | "require-dev": { 988 | "phpunit/phpunit": "~4.4" 989 | }, 990 | "type": "library", 991 | "extra": { 992 | "branch-alias": { 993 | "dev-master": "1.3.x-dev" 994 | } 995 | }, 996 | "autoload": { 997 | "classmap": [ 998 | "src/" 999 | ] 1000 | }, 1001 | "notification-url": "https://packagist.org/downloads/", 1002 | "license": [ 1003 | "BSD-3-Clause" 1004 | ], 1005 | "authors": [ 1006 | { 1007 | "name": "Sebastian Bergmann", 1008 | "email": "sebastian@phpunit.de" 1009 | } 1010 | ], 1011 | "description": "Provides functionality to handle HHVM/PHP environments", 1012 | "homepage": "http://www.github.com/sebastianbergmann/environment", 1013 | "keywords": [ 1014 | "Xdebug", 1015 | "environment", 1016 | "hhvm" 1017 | ], 1018 | "time": "2015-01-01 10:01:08" 1019 | }, 1020 | { 1021 | "name": "sebastian/exporter", 1022 | "version": "1.2.0", 1023 | "source": { 1024 | "type": "git", 1025 | "url": "https://github.com/sebastianbergmann/exporter.git", 1026 | "reference": "84839970d05254c73cde183a721c7af13aede943" 1027 | }, 1028 | "dist": { 1029 | "type": "zip", 1030 | "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/84839970d05254c73cde183a721c7af13aede943", 1031 | "reference": "84839970d05254c73cde183a721c7af13aede943", 1032 | "shasum": "" 1033 | }, 1034 | "require": { 1035 | "php": ">=5.3.3", 1036 | "sebastian/recursion-context": "~1.0" 1037 | }, 1038 | "require-dev": { 1039 | "phpunit/phpunit": "~4.4" 1040 | }, 1041 | "type": "library", 1042 | "extra": { 1043 | "branch-alias": { 1044 | "dev-master": "1.2.x-dev" 1045 | } 1046 | }, 1047 | "autoload": { 1048 | "classmap": [ 1049 | "src/" 1050 | ] 1051 | }, 1052 | "notification-url": "https://packagist.org/downloads/", 1053 | "license": [ 1054 | "BSD-3-Clause" 1055 | ], 1056 | "authors": [ 1057 | { 1058 | "name": "Jeff Welch", 1059 | "email": "whatthejeff@gmail.com" 1060 | }, 1061 | { 1062 | "name": "Volker Dusch", 1063 | "email": "github@wallbash.com" 1064 | }, 1065 | { 1066 | "name": "Bernhard Schussek", 1067 | "email": "bschussek@2bepublished.at" 1068 | }, 1069 | { 1070 | "name": "Sebastian Bergmann", 1071 | "email": "sebastian@phpunit.de" 1072 | }, 1073 | { 1074 | "name": "Adam Harvey", 1075 | "email": "aharvey@php.net" 1076 | } 1077 | ], 1078 | "description": "Provides the functionality to export PHP variables for visualization", 1079 | "homepage": "http://www.github.com/sebastianbergmann/exporter", 1080 | "keywords": [ 1081 | "export", 1082 | "exporter" 1083 | ], 1084 | "time": "2015-01-27 07:23:06" 1085 | }, 1086 | { 1087 | "name": "sebastian/global-state", 1088 | "version": "1.0.0", 1089 | "source": { 1090 | "type": "git", 1091 | "url": "https://github.com/sebastianbergmann/global-state.git", 1092 | "reference": "c7428acdb62ece0a45e6306f1ae85e1c05b09c01" 1093 | }, 1094 | "dist": { 1095 | "type": "zip", 1096 | "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/c7428acdb62ece0a45e6306f1ae85e1c05b09c01", 1097 | "reference": "c7428acdb62ece0a45e6306f1ae85e1c05b09c01", 1098 | "shasum": "" 1099 | }, 1100 | "require": { 1101 | "php": ">=5.3.3" 1102 | }, 1103 | "require-dev": { 1104 | "phpunit/phpunit": "~4.2" 1105 | }, 1106 | "suggest": { 1107 | "ext-uopz": "*" 1108 | }, 1109 | "type": "library", 1110 | "extra": { 1111 | "branch-alias": { 1112 | "dev-master": "1.0-dev" 1113 | } 1114 | }, 1115 | "autoload": { 1116 | "classmap": [ 1117 | "src/" 1118 | ] 1119 | }, 1120 | "notification-url": "https://packagist.org/downloads/", 1121 | "license": [ 1122 | "BSD-3-Clause" 1123 | ], 1124 | "authors": [ 1125 | { 1126 | "name": "Sebastian Bergmann", 1127 | "email": "sebastian@phpunit.de" 1128 | } 1129 | ], 1130 | "description": "Snapshotting of global state", 1131 | "homepage": "http://www.github.com/sebastianbergmann/global-state", 1132 | "keywords": [ 1133 | "global state" 1134 | ], 1135 | "time": "2014-10-06 09:23:50" 1136 | }, 1137 | { 1138 | "name": "sebastian/recursion-context", 1139 | "version": "1.0.0", 1140 | "source": { 1141 | "type": "git", 1142 | "url": "https://github.com/sebastianbergmann/recursion-context.git", 1143 | "reference": "3989662bbb30a29d20d9faa04a846af79b276252" 1144 | }, 1145 | "dist": { 1146 | "type": "zip", 1147 | "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/3989662bbb30a29d20d9faa04a846af79b276252", 1148 | "reference": "3989662bbb30a29d20d9faa04a846af79b276252", 1149 | "shasum": "" 1150 | }, 1151 | "require": { 1152 | "php": ">=5.3.3" 1153 | }, 1154 | "require-dev": { 1155 | "phpunit/phpunit": "~4.4" 1156 | }, 1157 | "type": "library", 1158 | "extra": { 1159 | "branch-alias": { 1160 | "dev-master": "1.0.x-dev" 1161 | } 1162 | }, 1163 | "autoload": { 1164 | "classmap": [ 1165 | "src/" 1166 | ] 1167 | }, 1168 | "notification-url": "https://packagist.org/downloads/", 1169 | "license": [ 1170 | "BSD-3-Clause" 1171 | ], 1172 | "authors": [ 1173 | { 1174 | "name": "Jeff Welch", 1175 | "email": "whatthejeff@gmail.com" 1176 | }, 1177 | { 1178 | "name": "Sebastian Bergmann", 1179 | "email": "sebastian@phpunit.de" 1180 | }, 1181 | { 1182 | "name": "Adam Harvey", 1183 | "email": "aharvey@php.net" 1184 | } 1185 | ], 1186 | "description": "Provides functionality to recursively process PHP variables", 1187 | "homepage": "http://www.github.com/sebastianbergmann/recursion-context", 1188 | "time": "2015-01-24 09:48:32" 1189 | }, 1190 | { 1191 | "name": "sebastian/version", 1192 | "version": "1.0.5", 1193 | "source": { 1194 | "type": "git", 1195 | "url": "https://github.com/sebastianbergmann/version.git", 1196 | "reference": "ab931d46cd0d3204a91e1b9a40c4bc13032b58e4" 1197 | }, 1198 | "dist": { 1199 | "type": "zip", 1200 | "url": "https://api.github.com/repos/sebastianbergmann/version/zipball/ab931d46cd0d3204a91e1b9a40c4bc13032b58e4", 1201 | "reference": "ab931d46cd0d3204a91e1b9a40c4bc13032b58e4", 1202 | "shasum": "" 1203 | }, 1204 | "type": "library", 1205 | "autoload": { 1206 | "classmap": [ 1207 | "src/" 1208 | ] 1209 | }, 1210 | "notification-url": "https://packagist.org/downloads/", 1211 | "license": [ 1212 | "BSD-3-Clause" 1213 | ], 1214 | "authors": [ 1215 | { 1216 | "name": "Sebastian Bergmann", 1217 | "email": "sebastian@phpunit.de", 1218 | "role": "lead" 1219 | } 1220 | ], 1221 | "description": "Library that helps with managing the version number of Git-hosted PHP projects", 1222 | "homepage": "https://github.com/sebastianbergmann/version", 1223 | "time": "2015-02-24 06:35:25" 1224 | }, 1225 | { 1226 | "name": "symfony/event-dispatcher", 1227 | "version": "v2.6.6", 1228 | "target-dir": "Symfony/Component/EventDispatcher", 1229 | "source": { 1230 | "type": "git", 1231 | "url": "https://github.com/symfony/EventDispatcher.git", 1232 | "reference": "70f7c8478739ad21e3deef0d977b38c77f1fb284" 1233 | }, 1234 | "dist": { 1235 | "type": "zip", 1236 | "url": "https://api.github.com/repos/symfony/EventDispatcher/zipball/70f7c8478739ad21e3deef0d977b38c77f1fb284", 1237 | "reference": "70f7c8478739ad21e3deef0d977b38c77f1fb284", 1238 | "shasum": "" 1239 | }, 1240 | "require": { 1241 | "php": ">=5.3.3" 1242 | }, 1243 | "require-dev": { 1244 | "psr/log": "~1.0", 1245 | "symfony/config": "~2.0,>=2.0.5", 1246 | "symfony/dependency-injection": "~2.6", 1247 | "symfony/expression-language": "~2.6", 1248 | "symfony/phpunit-bridge": "~2.7", 1249 | "symfony/stopwatch": "~2.3" 1250 | }, 1251 | "suggest": { 1252 | "symfony/dependency-injection": "", 1253 | "symfony/http-kernel": "" 1254 | }, 1255 | "type": "library", 1256 | "extra": { 1257 | "branch-alias": { 1258 | "dev-master": "2.6-dev" 1259 | } 1260 | }, 1261 | "autoload": { 1262 | "psr-0": { 1263 | "Symfony\\Component\\EventDispatcher\\": "" 1264 | } 1265 | }, 1266 | "notification-url": "https://packagist.org/downloads/", 1267 | "license": [ 1268 | "MIT" 1269 | ], 1270 | "authors": [ 1271 | { 1272 | "name": "Symfony Community", 1273 | "homepage": "http://symfony.com/contributors" 1274 | }, 1275 | { 1276 | "name": "Fabien Potencier", 1277 | "email": "fabien@symfony.com" 1278 | } 1279 | ], 1280 | "description": "Symfony EventDispatcher Component", 1281 | "homepage": "http://symfony.com", 1282 | "time": "2015-03-13 17:37:22" 1283 | }, 1284 | { 1285 | "name": "symfony/finder", 1286 | "version": "v2.6.6", 1287 | "target-dir": "Symfony/Component/Finder", 1288 | "source": { 1289 | "type": "git", 1290 | "url": "https://github.com/symfony/Finder.git", 1291 | "reference": "5dbe2e73a580618f5b4880fda93406eed25de251" 1292 | }, 1293 | "dist": { 1294 | "type": "zip", 1295 | "url": "https://api.github.com/repos/symfony/Finder/zipball/5dbe2e73a580618f5b4880fda93406eed25de251", 1296 | "reference": "5dbe2e73a580618f5b4880fda93406eed25de251", 1297 | "shasum": "" 1298 | }, 1299 | "require": { 1300 | "php": ">=5.3.3" 1301 | }, 1302 | "require-dev": { 1303 | "symfony/phpunit-bridge": "~2.7" 1304 | }, 1305 | "type": "library", 1306 | "extra": { 1307 | "branch-alias": { 1308 | "dev-master": "2.6-dev" 1309 | } 1310 | }, 1311 | "autoload": { 1312 | "psr-0": { 1313 | "Symfony\\Component\\Finder\\": "" 1314 | } 1315 | }, 1316 | "notification-url": "https://packagist.org/downloads/", 1317 | "license": [ 1318 | "MIT" 1319 | ], 1320 | "authors": [ 1321 | { 1322 | "name": "Symfony Community", 1323 | "homepage": "http://symfony.com/contributors" 1324 | }, 1325 | { 1326 | "name": "Fabien Potencier", 1327 | "email": "fabien@symfony.com" 1328 | } 1329 | ], 1330 | "description": "Symfony Finder Component", 1331 | "homepage": "http://symfony.com", 1332 | "time": "2015-03-30 15:54:10" 1333 | }, 1334 | { 1335 | "name": "symfony/process", 1336 | "version": "v2.6.6", 1337 | "target-dir": "Symfony/Component/Process", 1338 | "source": { 1339 | "type": "git", 1340 | "url": "https://github.com/symfony/Process.git", 1341 | "reference": "a8bebaec1a9dc6cde53e0250e32917579b0be552" 1342 | }, 1343 | "dist": { 1344 | "type": "zip", 1345 | "url": "https://api.github.com/repos/symfony/Process/zipball/a8bebaec1a9dc6cde53e0250e32917579b0be552", 1346 | "reference": "a8bebaec1a9dc6cde53e0250e32917579b0be552", 1347 | "shasum": "" 1348 | }, 1349 | "require": { 1350 | "php": ">=5.3.3" 1351 | }, 1352 | "require-dev": { 1353 | "symfony/phpunit-bridge": "~2.7" 1354 | }, 1355 | "type": "library", 1356 | "extra": { 1357 | "branch-alias": { 1358 | "dev-master": "2.6-dev" 1359 | } 1360 | }, 1361 | "autoload": { 1362 | "psr-0": { 1363 | "Symfony\\Component\\Process\\": "" 1364 | } 1365 | }, 1366 | "notification-url": "https://packagist.org/downloads/", 1367 | "license": [ 1368 | "MIT" 1369 | ], 1370 | "authors": [ 1371 | { 1372 | "name": "Symfony Community", 1373 | "homepage": "http://symfony.com/contributors" 1374 | }, 1375 | { 1376 | "name": "Fabien Potencier", 1377 | "email": "fabien@symfony.com" 1378 | } 1379 | ], 1380 | "description": "Symfony Process Component", 1381 | "homepage": "http://symfony.com", 1382 | "time": "2015-03-30 15:54:10" 1383 | } 1384 | ], 1385 | "aliases": [], 1386 | "minimum-stability": "stable", 1387 | "stability-flags": [], 1388 | "prefer-stable": false, 1389 | "prefer-lowest": false, 1390 | "platform": [], 1391 | "platform-dev": [] 1392 | } 1393 | -------------------------------------------------------------------------------- /eg.yml: -------------------------------------------------------------------------------- 1 | output_path: ./build 2 | mount: 3 | - {src: "./src", dest: "/somewhere"} 4 | - {src: "./spec", dest: "/usr/share/mysw"} 5 | control: 6 | package: my-package-name 7 | version: 0.0.1 8 | depends: php5, php5-cli, php5-curl 9 | maintainer: Walter Dal Mut [an-email@email.tld] 10 | provides: something, something-else 11 | replaces: first-package, second-package 12 | suggests: php5-mcrypt, php5-xsl 13 | pre_depends: build-essentials, libc6 14 | architecture: all 15 | section: web 16 | -------------------------------------------------------------------------------- /phpspec.yml: -------------------------------------------------------------------------------- 1 | suites: 2 | src_suite: 3 | namespace: Corley\Deb\Describe 4 | psr4_prefix: Corley\Deb\Describe 5 | src_path: 'src' 6 | spec_path: '.' 7 | -------------------------------------------------------------------------------- /spec/DescriberSpec.php: -------------------------------------------------------------------------------- 1 | beConstructedWith($parser, $packager); 16 | } 17 | 18 | function it_is_initializable() 19 | { 20 | $this->shouldHaveType('Corley\Deb\Describe\Describer'); 21 | } 22 | 23 | function it_should_compose_the_deb(Parser $parser, Packager $packager, StandardFile $control) 24 | { 25 | $packager->run()->willReturn($packager); 26 | $packager->build()->willReturn("dpkg -b something.deb"); 27 | $packager->getControl()->willReturn($control); 28 | 29 | $packager->setOutputPath("/path/to/out")->shouldBeCalledTimes(1); 30 | $packager->mount("/here", "/mnt/one")->shouldBeCalledTimes(1); 31 | $packager->mount("/here2", "/mnt/two")->shouldBeCalledTimes(1); 32 | 33 | $control->offsetSet("Package-Name", "my-package-name")->shouldBeCalledTimes(1); 34 | $control->offsetSet("Version", "0.0.1")->shouldBeCalledTimes(1); 35 | 36 | $yml = [ 37 | "output_path" => "/path/to/out", 38 | "control" => [ 39 | "package_name" => "my-package-name", 40 | "version" => "0.0.1", 41 | ], 42 | "mount" => [ 43 | ["src" => "/here", "dest" => "/mnt/one"], 44 | ["src" => "/here2", "dest" => "/mnt/two"], 45 | ], 46 | ]; 47 | 48 | $parser->parse(Argument::Any())->willReturn($yml); 49 | $this->compose("parser is mocked out")->shouldReturn("dpkg -b something.deb"); 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /spec/KeyFilterSpec.php: -------------------------------------------------------------------------------- 1 | shouldHaveType('Corley\Deb\Describe\KeyFilter'); 13 | } 14 | 15 | function it_should_convert_simple_param() 16 | { 17 | $this->filter("depends")->shouldReturn("Depends"); 18 | } 19 | 20 | function it_should_convert_underscores() 21 | { 22 | $this->filter("pre_depends")->shouldReturn("Pre-Depends"); 23 | } 24 | 25 | function it_should_convert_multiple_underscores() 26 | { 27 | $this->filter("pre_pre_depends")->shouldReturn("Pre-Pre-Depends"); 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /src/Describer.php: -------------------------------------------------------------------------------- 1 | parser = $parser; 18 | $this->packager = $packager; 19 | 20 | $this->keyFilter = new KeyFilter(); 21 | } 22 | 23 | public function setKeyFilter($keyFilter) 24 | { 25 | $this->keyFilter = $keyFilter; 26 | } 27 | 28 | public function compose($yml) 29 | { 30 | $yml = $this->parser->parse($yml); 31 | 32 | foreach ($yml as $key => $value) { 33 | switch ($key) { 34 | case "control": 35 | foreach ($value as $k => $v) { 36 | $method = $this->keyFilter->filter($k); 37 | $this->packager->getControl()[$method] = $v; 38 | } 39 | break; 40 | case "mount": 41 | foreach ($value as $line) { 42 | $this->packager->mount($line["src"], $line["dest"]); 43 | } 44 | break; 45 | default: 46 | $method = "set" . str_replace(' ', '', ucwords(str_replace('_', ' ', $key))); 47 | call_user_func([$this->packager, $method], $value); 48 | } 49 | } 50 | 51 | return $this->packager->run()->build(); 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /src/KeyFilter.php: -------------------------------------------------------------------------------- 1 | setName('package') 20 | ->setDescription('Create the .deb package') 21 | ->addArgument( 'name', 22 | InputArgument::REQUIRED, 23 | 'The source yml file thats will generate a deb file' 24 | ) 25 | ; 26 | } 27 | 28 | protected function execute(InputInterface $input, OutputInterface $output) 29 | { 30 | $parser = new Parser(); 31 | 32 | $packager = new Packager(); 33 | $packager->setControl(new StandardFile()); 34 | 35 | $describer = new Describer($parser, $packager); 36 | $command = $describer->compose(file_get_contents($input->getArgument("name"))); 37 | 38 | $output->writeln($command); 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /tests/DescriberTest.php: -------------------------------------------------------------------------------- 1 | root = vfsStream::setup('root'); 19 | 20 | $packager = $this->getMockBuilder("wdm\\debian\\Packager")->setMethods(["getOutputPath"])->getMock(); 21 | $packager->method("getOutputPath")->willReturn(vfsStream::url('root/tmp')); 22 | $packager->setControl(new StandardFile()); 23 | 24 | $this->object = new Describer($parser, $packager); 25 | } 26 | 27 | public function testPrepareIt() 28 | { 29 | $yml = <<assertEquals("dpkg -b vfs://root/tmp tmp.deb", $this->object->compose($yml)); 49 | 50 | $this->assertTrue($this->root->hasChild('tmp/DEBIAN/control')); 51 | $content = file_get_contents(vfsStream::url("root/tmp/DEBIAN/control")); 52 | 53 | $this->assertEquals(<<parser = new Parser(); 13 | } 14 | 15 | public function testSimpleParse() 16 | { 17 | $yml = $this->parser->parse(<<assertInternalType("array", $yml); 35 | $this->assertEquals("/path/to/out", $yml["output_path"]); 36 | $this->assertInternalType("array", $yml["control"]["depends"]); 37 | $this->assertCount(2, $yml["control"]["depends"]); 38 | } 39 | } 40 | --------------------------------------------------------------------------------