endSection() public method

Call this method when leaving the last pushed section of the packager.
public endSection ( )
コード例 #1
0
ファイル: packager.php プロジェクト: apigraf/xsolla-sdk-php
<?php

require __DIR__ . '/../vendor/autoload.php';
$packager = new \Burgomaster(__DIR__ . '/artifacts/staging', __DIR__ . '/../');
$packager->exec('rm -rf ' . __DIR__ . '/artifacts/xsolla.*');
$packager->recursiveCopy('src', 'Xsolla/SDK');
$packager->recursiveCopy('vendor/guzzle/guzzle/src/Guzzle', 'Guzzle', array('php', 'pem'));
$packager->recursiveCopy('vendor/symfony/event-dispatcher', 'Symfony/Component/EventDispatcher');
$packager->recursiveCopy('vendor/symfony/http-foundation', 'Symfony/Component/HttpFoundation');
$packager->createAutoloader(array(), 'xsolla-autoloader.php');
$packager->createPhar(__DIR__ . '/artifacts/xsolla.phar', null, 'xsolla-autoloader.php');
$packager->createZip(__DIR__ . '/artifacts/xsolla.zip');
$packager->startSection('test-phar');
$packager->exec('php ' . __DIR__ . '/test-phar.php');
$packager->endSection();
$packager->exec('rm -rf ' . __DIR__ . '/artifacts/staging');
コード例 #2
0
ファイル: packager.php プロジェクト: allan2012/laraspiked
<?php

require __DIR__ . '/artifacts/Burgomaster.php';
$stageDirectory = __DIR__ . '/artifacts/staging';
$projectRoot = __DIR__ . '/../';
$burgomaster = new \Burgomaster($stageDirectory, $projectRoot);
$metaFiles = ['README.md', 'LICENSE.md', 'NOTICE.md', 'CHANGELOG.md'];
foreach ($metaFiles as $file) {
    $burgomaster->deepCopy($file, $file);
}
// Copy each dependency to the staging directory. Copy *.php and *.pem files.
$burgomaster->recursiveCopy('src/Aws', 'Aws', ['php', 'json']);
$burgomaster->recursiveCopy('vendor/guzzle/guzzle/src/Guzzle', 'Guzzle', ['php', 'pem']);
$burgomaster->recursiveCopy('vendor/doctrine/cache/lib/Doctrine', 'Doctrine');
$burgomaster->recursiveCopy('vendor/psr/log/Psr', 'Psr');
$burgomaster->recursiveCopy('vendor/monolog/monolog/src/Monolog', 'Monlog');
$burgomaster->recursiveCopy('vendor/symfony/event-dispatcher/Symfony', 'Symfony');
$burgomaster->createAutoloader();
$burgomaster->createZip(__DIR__ . '/artifacts/aws.zip');
$burgomaster->createPhar(__DIR__ . '/artifacts/aws.phar');
$burgomaster->startSection('test_phar');
$burgomaster->debug('Phar output: ' . $burgomaster->exec('php ' . __DIR__ . '/test_phar.php'));
$burgomaster->endSection();