aboutsummaryrefslogtreecommitdiff
path: root/bin/makephar.php
diff options
context:
space:
mode:
authorChristian Weiske <cweiske@cweiske.de>2014-03-12 06:42:10 +0100
committerChristian Weiske <cweiske@cweiske.de>2014-03-12 06:42:51 +0100
commitde289237fb227b373274fc6a029cddfbed9f802a (patch)
treebcb944bfed58319a0c126bfdde77ab115ca17b14 /bin/makephar.php
parent6d93322bd314ffe59bdd12e525c7511e43037dfd (diff)
downloadbdrem-de289237fb227b373274fc6a029cddfbed9f802a.tar.gz
bdrem-de289237fb227b373274fc6a029cddfbed9f802a.zip
Remove manual phar building scripts
Diffstat (limited to 'bin/makephar.php')
-rwxr-xr-xbin/makephar.php31
1 files changed, 0 insertions, 31 deletions
diff --git a/bin/makephar.php b/bin/makephar.php
deleted file mode 100755
index 13c1acd..0000000
--- a/bin/makephar.php
+++ /dev/null
@@ -1,31 +0,0 @@
-#!/usr/bin/env php
-<?php
-if (ini_get('phar.readonly') == 1) {
- //re-run this script with phar writing activated
- passthru(PHP_BINARY . ' -dphar.readonly=0 ' . escapeshellarg($argv[0]));
- exit();
-}
-
-$pharfile = __DIR__ . '/../dist/bdrem-0.1.0.phar';
-if (file_exists($pharfile)) {
- unlink($pharfile);
-}
-$phar = new Phar($pharfile, 0, 'bdrem.phar');
-$phar->startBuffering();
-
-// add all files in the project
-$phar->buildFromDirectory(
- realpath(__DIR__ . '/../'),
- '#'
- . '^' . preg_quote(realpath(__DIR__ . '/../'), '#')
- . '/(data/bdrem.config.php.dist|lib/|src/bdrem/|www/|README\.rst)'
- . '#'
-);
-
-//remove shebang from bin/bdrem.php
-$bin = file_get_contents(__DIR__ . '/../bin/bdrem.php');
-$phar->addFromString('bin/bdrem.php', substr($bin, strpos($bin, "\n") + 1));
-
-$phar->setStub(file_get_contents(__DIR__ . '/../src/phar-stub.php'));
-$phar->stopBuffering();
-?>