Allow renaming of shpub.phar to shpub
authorChristian Weiske <weiske@mogic.com>
Mon, 28 Aug 2017 10:32:31 +0000 (12:32 +0200)
committerChristian Weiske <weiske@mogic.com>
Mon, 28 Aug 2017 10:32:31 +0000 (12:32 +0200)
Resolves: https://github.com/cweiske/shpub/issues/7
Solution: https://cweiske.de/tagebuch/phar-renaming-no-ext.htm

src/phar-stub.php

index 653c0d0..5ffe5c7 100644 (file)
@@ -15,7 +15,7 @@ if (!in_array('phar', stream_get_wrappers()) || !class_exists('Phar', false)) {
     exit(255);
 }
 
-//Phar::interceptFileFuncs();
+Phar::mapPhar('shpub.phar');
 set_include_path(
     'phar://' . __FILE__
     . PATH_SEPARATOR . 'phar://' . __FILE__ . '/lib/'