PHPackages                             barkley/create-phar - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. barkley/create-phar

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

barkley/create-phar
===================

PHP packaging and build process

2.2.7(11mo ago)165MITPHPPHP &gt;=8.1

Since Oct 27Pushed 11mo ago2 watchersCompare

[ Source](https://github.com/BarkleyREI/create-phar)[ Packagist](https://packagist.org/packages/barkley/create-phar)[ RSS](/packages/barkley-create-phar/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (5)Versions (18)Used By (0)

create-phar
===========

[](#create-phar)

Overview
--------

[](#overview)

This project will aid in creating PHP projects that following Barkley's typical development flow, and will allow the creation of versioned PHAR files for projects to be easily distributed to systems that are detached from any code repository.

> *Barkley's PHP development process is ever-changing, so updates and changes to this project will likely shift around frequently as well. However, backwards-compatibility will always be important as we move forward. We will intend to support the ability to disable any new features that get added.*

Setup
-----

[](#setup)

### Composer

[](#composer)

> *Composer support has been introduced in v2.0.0, and is relatively fresh, so proceed with caution. This will be supported on Linux.*

#### Install

[](#install)

Install the Composer package `barkley/create-phar` ([see Packagist](https://packagist.org/packages/barkley/create-phar)).

```
composer require barkley/create-phar
```

Version set to `dev-master` will pull directly from the master branch, which may include work-in-progress changes. It is suggested to lock your install to a specific version instead.

**create-phar** needs to be installed in the root of your project, rather than the source directory. The initialization will help structure the project.

#### Usage

[](#usage)

Once installed, the following script, run from the root of your project, will allow access to all **create-phar**logic.

```
./vendor/bin/create-phar
```

Prior to version 2.1.1, you would need to use the following script:

```
php vendor/barkley/create-phar/build.php
```

(*Anytime instructions below refer to the command `create-phar`, you will need to use this path instead)*

### Windows

[](#windows)

Add the directory for the create-phar project to your system's PATH variable. If done correctly you should see output when you type `create-phar`in your system's terminal.

Project Initialization
----------------------

[](#project-initialization)

To initialize a new project, create an empty directory for it, and within it run the command `create-phar init`.

The project will be named and namespaced based on the current directory. For example, if you run `create-phar init` in the directory *c:\\TestProject\\*, your project will have the name *Testproject* and be in the namespace *rei\\TestProject*.

Configuration
-------------

[](#configuration)

**TO DO**

Project Build
-------------

[](#project-build)

To build projects after initialization, simply run the command `create-phar` within the project directory.

If you want to change the version number for the project, run the command followed by the new version number. For example `create-phar 1.2.4`.

Run Flags
---------

[](#run-flags)

- `-h` - Outputs help commands.
- `-v` - Runs in verbose mode, providing more output during the build process.
- `-u` - Updates Composer and dependencies. By default, running a build does not update these items.
- `-i` - Outputs version information on the current project without doing any build steps.
- `-c` - Run a Composer command against the curent project using the Composer from the create-phar build.
- `-fixpsr` - Fix PSR adjustments. Should only need to be run if prompted to do so.

###  Health Score

35

—

LowBetter than 79% of packages

Maintenance51

Moderate activity, may be stable

Popularity10

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~39 days

Recently: every ~45 days

Total

16

Last Release

343d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/faab90234400441c7f22ada194372462e543ddcd30685a124570891af1583eb9?d=identicon)[tyllyn](/maintainers/tyllyn)

---

Top Contributors

[![tyllyn](https://avatars.githubusercontent.com/u/159615?v=4)](https://github.com/tyllyn "tyllyn (82 commits)")

###  Code Quality

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/barkley-create-phar/health.svg)

```
[![Health](https://phpackages.com/badges/barkley-create-phar/health.svg)](https://phpackages.com/packages/barkley-create-phar)
```

###  Alternatives

[shyim/danger-php

Port of danger to PHP

8544.9k](/packages/shyim-danger-php)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.3M152](/packages/sulu-sulu)[internal/dload

Downloads binaries.

98142.7k10](/packages/internal-dload)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

595.2M386](/packages/shopware-core)[netgen/layouts-core

Netgen Layouts enables you to build and manage complex web pages in a simpler way and with less coding. This is the core of Netgen Layouts, its heart and soul.

3689.4k10](/packages/netgen-layouts-core)[aeliot/todo-registrar

Register TODOs from source code in issue tracker

153.0k](/packages/aeliot-todo-registrar)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
