pharmaker is a quick php script to build a phar file out of a directory with default scripts for web and cli
Latest commit 5327594 Sep 3, 2013 @masnun Executable Phar generation
Failed to load latest commit information.
src initial commit Jan 25, 2013 initial commit Jan 25, 2013
makephar Executable Phar generation Sep 3, 2013
mphar.phar initial commit Jan 25, 2013


Simple PHAR build tool to convert a directory into a PHAR archive

Basic Concepts

Source Directory: The directory that contains the source php files.
PHAR Name: The name which identifies the Phar. The name is used to generate the phar archive as well as to refer to the archive in phar:// steam contexts.
CLI Script: The script which is executed when the archive is run from the command line. index.php is assumed if not provided.
Web Script: The script which is by default executed in the web environment. Defaults to CLI script value if not provided with.

Building Basics

./makephar <source dir> <phar name> [<cli script> <web script>]

Example: The following command will create a phar archive named mphar.phar with cli.php as cli script and web.php as the web script

./makephar src mphar.phar cli.php web.php

==========: STARTING PHAR BUILD PROCESS :==========
Source Directory: src
PHAR Name: mphar.phar
CLI Script: cli.php
Web Script: web.php
DONE: Built mphar.phar

Checkout the "src" directory for sample cli and web script