本文整理汇总了PHP中Phar::setSignatureAlgorithm方法的典型用法代码示例。如果您正苦于以下问题:PHP Phar::setSignatureAlgorithm方法的具体用法?PHP Phar::setSignatureAlgorithm怎么用?PHP Phar::setSignatureAlgorithm使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Phar
的用法示例。
在下文中一共展示了Phar::setSignatureAlgorithm方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: build
public function build($filename, $stub)
{
if (file_exists($filename)) {
unlink($filename);
}
$phar = new \Phar($filename, 0, $this->aliasName != '' ? $this->aliasName : basename($filename));
$phar->startBuffering();
$phar->setStub($stub);
if ($this->key !== NULL) {
$privateKey = '';
openssl_pkey_export($this->key, $privateKey);
$phar->setSignatureAlgorithm(\Phar::OPENSSL, $privateKey);
$keyDetails = openssl_pkey_get_details($this->key);
file_put_contents($filename . '.pubkey', $keyDetails['key']);
} else {
$phar->setSignatureAlgorithm($this->selectSignatureType($phar));
}
$basedir = $this->basedir ? $this->basedir : $this->directories[0];
foreach ($this->directories as $directory) {
$phar->buildFromIterator($this->scanner->__invoke($directory), $basedir);
}
if ($this->compression !== \Phar::NONE) {
$phar->compressFiles($this->compression);
}
$phar->stopBuffering();
}
示例2: compile
/**
* Compiles composer into a single phar file
*
* @throws \RuntimeException
*
* @param string $pharFile The full path to the file to create
*/
public function compile($pharFile = 'swagger.phar')
{
if (file_exists($pharFile)) {
unlink($pharFile);
}
$this->version = trim(file_get_contents(dirname(__DIR__ . '/VERSION')));
$phar = new \Phar($pharFile, 0, 'swagger.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->notName('Compiler.php')->notName('ClassLoader.php')->notPath('vendor/symfony')->notPath('tests')->in(dirname(__DIR__) . '/');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$this->addFile($phar, new \SplFileInfo(dirname(__DIR__) . '/vendor/autoload.php'));
$this->addFile($phar, new \SplFileInfo(dirname(__DIR__) . '/vendor/composer/autoload_namespaces.php'));
$this->addFile($phar, new \SplFileInfo(dirname(__DIR__) . '/vendor/composer/autoload_classmap.php'));
$this->addFile($phar, new \SplFileInfo(dirname(__DIR__) . '/vendor/composer/ClassLoader.php'));
$this->addSwaggerBin($phar);
$phar->setStub($this->getStub());
$phar->stopBuffering();
$this->addFile($phar, new \SplFileInfo(dirname(__DIR__) . '/LICENSE-2.0.txt'), false);
$this->addFile($phar, new \SplFileInfo(dirname(__DIR__) . '/VERSION'), false);
unset($phar);
}
示例3: compile
/**
* Compiles psysh into a single phar file
*
* @param string $pharFile The full path to the file to create
*/
public function compile($pharFile = 'psysh.phar')
{
if (file_exists($pharFile)) {
unlink($pharFile);
}
$this->version = Shell::VERSION;
$phar = new \Phar($pharFile, 0, 'psysh.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->notName('Compiler.php')->notName('Autoloader.php')->in(__DIR__ . '/..');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->exclude('Tests')->in(__DIR__ . '/../../vendor/symfony/')->in(__DIR__ . '/../../vendor/nikic/');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/autoload.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/include_paths.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_real.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_namespaces.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_classmap.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/ClassLoader.php'));
$this->addPsyshBin($phar);
// Stubs
$phar->setStub($this->getStub());
$phar->stopBuffering();
// $this->addFile($phar, new \SplFileInfo(__DIR__.'/../../LICENSE'), false);
unset($phar);
}
示例4: makePlugin
/**
* Makes a .phar packaged PocketMine plugin from a source directory.
*
* @param $sourcePath
* @param $pharOutputLocation
* @param $options
* @return bool
* @throws \Exception
*/
public static function makePlugin($sourcePath, $pharOutputLocation, $options)
{
/* Removes Leading '/' */
$sourcePath = rtrim(str_replace("\\", "/", realpath($sourcePath)), "/") . "/";
$description = self::getPluginDescription($sourcePath . "/plugin.yml");
if ($options & self::MAKEPLUGIN_REAL_OUTPUT_PATH) {
$pharPath = $pharOutputLocation;
} else {
$pharPath = $pharOutputLocation . DIRECTORY_SEPARATOR . $description->getName() . "_v" . $description->getVersion() . ".phar";
}
if (file_exists($pharPath)) {
throw new \Exception("Phar path already exists");
}
$phar = new \Phar($pharPath);
$phar->setMetadata(["name" => $description->getName(), "version" => $description->getVersion(), "main" => $description->getMain(), "api" => $description->getCompatibleApis(), "depend" => $description->getDepend(), "description" => $description->getDescription(), "authors" => $description->getAuthors(), "website" => $description->getWebsite(), "creationDate" => time()]);
$phar->setStub('<?php echo "PocketMine-MP plugin ' . $description->getName() . ' v' . $description->getVersion() . '\\nThis file has been generated using DevTools v' . self::getVersion() . ' at ' . date("r") . '\\n----------------\\n";if(extension_loaded("phar")){$phar = new \\Phar(__FILE__);foreach($phar->getMetadata() as $key => $value){echo ucfirst($key).": ".(is_array($value) ? implode(", ", $value):$value)."\\n";}} __HALT_COMPILER();');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
foreach (new \RecursiveIteratorIterator(new \RecursiveDirectoryIterator($sourcePath)) as $file) {
$path = ltrim(str_replace(["\\", $sourcePath], ["/", ""], $file), "/");
if ($path[0] === "." or strpos($path, "/.") !== false) {
continue;
}
$phar->addFile($file, $path);
}
if ($options * self::MAKEPLUGIN_COMPRESS) {
$phar->compressFiles(\Phar::GZ);
}
$phar->stopBuffering();
return true;
}
示例5: compile
public function compile()
{
if (file_exists('symfony.phar')) {
unlink('symfony.phar');
}
$phar = new \Phar('symfony.phar', 0, 'Symfony');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
// Files
foreach ($this->getFiles() as $file) {
$path = str_replace(__DIR__ . '/', '', $file);
if (false !== strpos($file, '.php')) {
$content = Kernel::stripComments(file_get_contents($file));
} else {
$content = file_get_contents($file);
}
$phar->addFromString($path, $content);
}
// Stubs
$phar['_cli_stub.php'] = $this->getCliStub();
$phar['_web_stub.php'] = $this->getWebStub();
$phar->setDefaultStub('_cli_stub.php', '_web_stub.php');
$phar->stopBuffering();
//$phar->compressFiles(\Phar::GZ);
unset($phar);
}
示例6: compile
public function compile($pharFile = 'already-extract.phar')
{
if (file_exists($pharFile)) {
unlink($pharFile);
}
$phar = new \Phar($pharFile, 0, 'already-extract.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->notName('Compiler.php')->in(__DIR__ . '/..');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->exclude('Tests')->in(__DIR__ . '/../../vendor/symfony/');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/autoload.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_namespaces.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_psr4.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_classmap.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_real.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/ClassLoader.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/include_paths.php'));
$this->addAlreadyExtractBin($phar);
$phar->setStub($this->getStub());
$phar->stopBuffering();
unset($phar);
}
示例7: compile
/**
* Compiles psysh into a single phar file.
*
* @param string $pharFile The full path to the file to create
*/
public function compile($pharFile = 'psysh.phar')
{
if (file_exists($pharFile)) {
unlink($pharFile);
}
$this->version = Shell::VERSION;
$phar = new \Phar($pharFile, 0, 'psysh.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finder = Finder::create()->files()->ignoreVCS(true)->name('*.php')->notName('Compiler.php')->notName('Autoloader.php')->in(__DIR__ . '/..');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$finder = Finder::create()->files()->ignoreVCS(true)->name('*.php')->exclude('Tests')->in(__DIR__ . '/../../vendor/dnoegel/php-xdg-base-dir/src')->in(__DIR__ . '/../../vendor/jakub-onderka/php-console-color')->in(__DIR__ . '/../../vendor/jakub-onderka/php-console-highlighter')->in(__DIR__ . '/../../vendor/nikic/php-parser/lib')->in(__DIR__ . '/../../vendor/symfony/console')->in(__DIR__ . '/../../vendor/symfony/var-dumper')->in(__DIR__ . '/../../vendor/symfony/yaml');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/autoload.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/include_paths.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_files.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_psr4.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_real.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_namespaces.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_classmap.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/ClassLoader.php'));
// Stubs
$phar->setStub($this->getStub());
$phar->stopBuffering();
// $this->addFile($phar, new \SplFileInfo(__DIR__.'/../../LICENSE'), false);
unset($phar);
}
示例8: compile
/**
* Compiles phar archive.
*
* @param string $version
*/
public function compile($version)
{
if (file_exists($package = "behat-{$version}.phar")) {
unlink($package);
}
// create phar
$phar = new \Phar($package, 0, 'behat.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->name('*.xsd')->name('*.xml')->name('LICENSE')->notName('PharCompiler.php')->notName('PearCompiler.php')->in($this->libPath . '/src')->in($this->libPath . '/vendor');
foreach ($finder as $file) {
// don't compile test suites
if (!preg_match('/\\/tests\\/|\\/test\\//i', $file->getRealPath())) {
$this->addFileToPhar($file, $phar);
}
}
// license and autoloading
$this->addFileToPhar(new \SplFileInfo($this->libPath . '/LICENSE'), $phar);
$this->addFileToPhar(new \SplFileInfo($this->libPath . '/i18n.php'), $phar);
// stub
$phar->setStub($this->getStub($version));
$phar->stopBuffering();
unset($phar);
}
示例9: compile
/**
* Compile.
*/
public function compile()
{
$pharFilePath = dirname(__FILE__) . '/../../build/monitor.phar';
if (file_exists($pharFilePath)) {
unlink($pharFilePath);
}
$this->loadVersion();
$phar = new \Phar($pharFilePath, 0, 'monitor.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$root = __DIR__ . '/../..';
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->name('LICENSE')->notName('Compiler.php')->exclude('Tests')->exclude('tests')->exclude('docs')->in($root . '/src')->in($root . '/vendor/guzzlehttp')->in($root . '/vendor/rtheunissen')->in($root . '/vendor/eljam')->in($root . '/vendor/hogosha')->in($root . '/vendor/webmozart')->in($root . '/vendor/psr')->in($root . '/vendor/guzzle')->in($root . '/vendor/symfony');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$this->addFile($phar, new \SplFileInfo($root . '/vendor/autoload.php'));
$this->addFile($phar, new \SplFileInfo($root . '/vendor/composer/autoload_namespaces.php'));
$this->addFile($phar, new \SplFileInfo($root . '/vendor/composer/autoload_psr4.php'));
$this->addFile($phar, new \SplFileInfo($root . '/vendor/composer/autoload_classmap.php'));
$this->addFile($phar, new \SplFileInfo($root . '/vendor/composer/autoload_files.php'));
$this->addFile($phar, new \SplFileInfo($root . '/vendor/composer/autoload_real.php'));
if (file_exists($root . '/vendor/composer/include_paths.php')) {
$this->addFile($phar, new \SplFileInfo($root . '/vendor/composer/include_paths.php'));
}
$this->addFile($phar, new \SplFileInfo($root . '/vendor/composer/ClassLoader.php'));
$binContent = file_get_contents($root . '/bin/monitor');
$binContent = preg_replace('{^#!/usr/bin/env php\\s*}', '', $binContent);
$phar->addFromString('bin/monitor', $binContent);
// Stubs
$phar->setStub($this->getStub());
$phar->stopBuffering();
unset($phar);
}
示例10: run
public function run()
{
$this->printTaskInfo("Creating <info>{$this->filename}</info>");
$this->phar->setSignatureAlgorithm(\Phar::SHA1);
$this->phar->startBuffering();
$this->printTaskInfo('Packing ' . count($this->files) . ' files into phar');
$progress = new ProgressBar($this->getOutput());
$progress->start(count($this->files));
$this->startTimer();
foreach ($this->files as $path => $content) {
$this->phar->addFromString($path, $content);
$progress->advance();
}
$this->phar->stopBuffering();
$progress->finish();
$this->getOutput()->writeln('');
if ($this->compress and in_array('GZ', \Phar::getSupportedCompression())) {
if (count($this->files) > 1000) {
$this->printTaskInfo("Too many files. Compression DISABLED");
} else {
$this->printTaskInfo($this->filename . " compressed");
$this->phar = $this->phar->compressFiles(\Phar::GZ);
}
}
$this->stopTimer();
$this->printTaskSuccess("<info>{$this->filename}</info> produced");
return Result::success($this, '', ['time' => $this->getExecutionTime()]);
}
示例11: compile
/**
* Compiles the Cilex source code into one single Phar file.
*
* @param string $pharFile Name of the output Phar file
*/
public function compile($pharFile = 'cilex.phar')
{
if (file_exists($pharFile)) {
unlink($pharFile);
}
$process = new Process('git log --pretty="%h %ci" -n1 HEAD');
if ($process->run() > 0) {
throw new \RuntimeException('The git binary cannot be found.');
}
$this->version = trim($process->getOutput());
$phar = new \Phar($pharFile, 0, 'cilex.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->notName('Compiler.php')->in(__DIR__ . '/..')->in(__DIR__ . '/../../vendor/pimple/pimple/lib')->in(__DIR__ . '/../../vendor/symfony/class-loader/Symfony/Component/ClassLoader')->in(__DIR__ . '/../../vendor/symfony/console/Symfony/Component/Console');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../LICENSE'), false);
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/autoload.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/ClassLoader.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_real.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_namespaces.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/composer/autoload_classmap.php'));
// Stubs
$phar->setStub($this->getStub());
$phar->stopBuffering();
// $phar->compressFiles(\Phar::GZ);
unset($phar);
}
示例12: compile
public function compile($pharFile = self::PHAR_FILE, $root_dir = null)
{
if (is_null($root_dir)) {
$this->root_dir = dirname(dirname(__DIR__)) . DIRECTORY_SEPARATOR;
} else {
$this->root_dir = rtrim($root_dir, DIRECTORY_SEPARATOR) . DIRECTORY_SEPARATOR;
}
if (file_exists($pharFile)) {
unlink($pharFile);
}
$phar = new \Phar($pharFile, 0, self::PHAR_NAME);
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finder = $this->getDefaultFinder();
$finder->name('*.php');
foreach ($finder as $file) {
$this->__addFile($phar, $file);
}
$finder = $this->getDefaultFinder();
$finder->name('*.json')->name('*.ini')->name('*.man')->name('*.md')->name('*.tpl')->name('LICENSE');
foreach ($finder as $file) {
$this->__addFile($phar, $file, false);
}
// global binary
$this->__addBin($phar);
// add the __stub
$phar->setStub($this->__getStub());
$phar->stopBuffering();
unset($phar);
return $this->_logs;
}
示例13: compile
/**
* Compiles the Silex source code into one single Phar file.
*
* @param string $pharFile Name of the output Phar file
*/
public function compile($pharFile = 'silex.phar')
{
if (file_exists($pharFile)) {
unlink($pharFile);
}
$process = new Process('git log --pretty="%h %ci" -n1 HEAD');
if ($process->run() > 0) {
throw new \RuntimeException('The git binary cannot be found.');
}
$this->version = trim($process->getOutput());
$phar = new \Phar($pharFile, 0, 'silex.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->notName('Compiler.php')->in(__DIR__ . '/..')->in(__DIR__ . '/../../vendor/pimple/pimple/lib')->in(__DIR__ . '/../../vendor/symfony/class-loader/Symfony/Component/ClassLoader')->in(__DIR__ . '/../../vendor/symfony/event-dispatcher/Symfony/Component/EventDispatcher')->in(__DIR__ . '/../../vendor/symfony/http-foundation/Symfony/Component/HttpFoundation')->in(__DIR__ . '/../../vendor/symfony/http-kernel/Symfony/Component/HttpKernel')->in(__DIR__ . '/../../vendor/symfony/routing/Symfony/Component/Routing')->in(__DIR__ . '/../../vendor/symfony/browser-kit/Symfony/Component/BrowserKit')->in(__DIR__ . '/../../vendor/symfony/css-selector/Symfony/Component/CssSelector')->in(__DIR__ . '/../../vendor/symfony/dom-crawler/Symfony/Component/DomCrawler');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../LICENSE'), false);
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/.composer/autoload.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/.composer/ClassLoader.php'));
$this->addFile($phar, new \SplFileInfo(__DIR__ . '/../../vendor/.composer/autoload_namespaces.php'));
// Stubs
$phar->setStub($this->getStub());
$phar->stopBuffering();
// $phar->compressFiles(\Phar::GZ);
unset($phar);
}
示例14: compile
/**
* Compile new composer.phar
* @param string $filename
*/
public function compile($filename = 'codecept.phar')
{
if (file_exists($filename)) {
unlink($filename);
}
$phar = new \Phar($filename, 0, 'codecept.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->name('*.tpl.dist')->name('*.html.dist')->in($this->compileDir . '/src');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->name('*.js')->name('*.css')->name('*.png')->name('*.tpl.dist')->name('*.html.dist')->exclude('Tests')->exclude('tests')->exclude('benchmark')->exclude('demo')->in($this->compileDir . '/plugins/frameworks');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->name('*.css')->name('*.png')->name('*.js')->name('*.css')->name('*.png')->name('*.tpl.dist')->name('*.html.dist')->exclude('Tests')->exclude('tests')->exclude('benchmark')->exclude('demo')->in($this->compileDir . '/vendor');
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
$this->addFile($phar, new \SplFileInfo($this->compileDir . '/autoload.php'));
$this->setMainExecutable($phar);
$this->setStub($phar);
$phar->stopBuffering();
unset($phar);
}
示例15: compile
public function compile($pharFile = 'onesky.phar')
{
if (file_exists($pharFile)) {
unlink($pharFile);
}
$phar = new \Phar($pharFile, 0, 'onesky.phar');
$phar->setSignatureAlgorithm(\Phar::SHA1);
$phar->startBuffering();
$finders = array();
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->notName('Compiler.php')->in(__DIR__);
$finders[] = $finder;
$finder = new Finder();
$finder->files()->ignoreVCS(true)->name('*.php')->in(dirname(__DIR__) . "/vendor");
$finders[] = $finder;
foreach ($finders as $finder) {
foreach ($finder as $file) {
$this->addFile($phar, $file);
}
}
$this->addBin($phar);
// Stubs
$phar->setStub($this->getStub());
$phar->stopBuffering();
$phar->compressFiles(\Phar::GZ);
unset($phar);
}