2017 © Pedro Peláez
 

library composer-config-reader

A light-weight component for reading Composer configuration files.

image

eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  • Thursday, November 2, 2017
  • by ezzatron
  • Repository
  • 3 Watchers
  • 24 Stars
  • 1,019,833 Installations
  • PHP
  • 10 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 10 Versions
  • 6 % Grown

The README.md

No longer maintained

This package is no longer maintained. See [this statement] for more info., (*1)

[this statement]: https://gist.github.com/ezzatron/713a548735febe3d76f8ca831bc895c0# Phony for PHPUnit, (*2)

Composer configuration reader

A light-weight component for reading Composer configuration files., (*3)

![Current version image][version-image] Current build status image ![Current coverage status image][coverage-image], (*4)

Installation and documentation

Usage

Composer configuration reader is very simple to use, and a quick example should be self-explanatory:, (*5)

$reader = new Eloquent\Composer\Configuration\ConfigurationReader;
$configuration = $reader->read('/path/to/composer.json');

echo $configuration->name(); // outputs the package name

Configuration objects

The following are the objects used to represent the configuration information. For a more detailed overview of the data available, simply look through the class definition (these classes are very simple)., (*6)

The following classes all exist in the Eloquent\Composer\Configuration\Element namespace., (*7)

Configuration

This is the main configuration object and has methods to access all the information available in the Composer schema., (*8)

Example methods

  • name(): The package name.
  • description(): The package description.
  • dependencies(): Equivalent to Composer require.
  • devDependencies(): Equivalent to Composer require-dev.
  • autoloadPSR0(): The autoload information for PSR-0 namespaces/paths.
  • autoloadClassmap(): The autoload information for classmapped paths.

Helper methods

A number of helper methods exist on the main configuration object to simplify the process of extracting useful information:, (*9)

  • projectName(): The project name without the vendor prefix.
  • vendorName(): The vendor name without the project suffix.
  • allDependencies(): Combines require and require-dev into a single array.
  • allPSR0SourcePaths(): A flat array of all PSR-0-compliant source paths.
  • allSourcePaths(): A flat array of all source paths.

Repository, PackageRepository

These objects describe the package's defined repositories., (*10)

All repositories are represented by the Repository class, except for package-type repositories which use the PackageRepository class., (*11)

See Repositories., (*12)

Example methods

  • type(): The repository type.
  • url(): The repository URL (not available for PackageRepository).

Stability

This object is an enumeration of package stabilities, with the following members:, (*13)

  • DEV
  • ALPHA
  • BETA
  • RC
  • STABLE

It is currently only used to represent the value of the minimum-stability option., (*14)

Author

This object contains all information provided for a specific author., (*15)

See authors., (*16)

Example methods

  • name(): The author's name.
  • email(): The author's email address.

SupportInformation

This object describes the package's support contact information., (*17)

See support., (*18)

Example methods

  • email(): The support email address.
  • issues(): The URL of the issue tracking system.
  • wiki(): The URL of the wiki system.

ProjectConfiguration

This object describes configuration options specific to end-projects, such as the target directories for various resources provided by Composer., (*19)

See config., (*20)

Example methods

  • vendorDir(): The project's vendor directory path.
  • binDir(): The project's binary directory path.

ScriptConfiguration

This object describes the Composer scripts defined by the package., (*21)

See Scripts., (*22)

Example methods

  • preInstallCmd(): The pre-install scripts.
  • postInstallCmd(): The post-install scripts.

ArchiveConfiguration

This object describes the settings for creating package archives., (*23)

See archive., (*24)

Example methods

  • exclude(): A list of file exclusion patterns.

The Versions

02/11 2017

dev-master

9999999-dev https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader

02/11 2017

2.1.0

2.1.0.0 https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader

20/12 2016

2.0.2

2.0.2.0 https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader

23/06 2016

dev-release-2.0.1

dev-release-2.0.1 https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader

23/06 2016

2.0.1

2.0.1.0 https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader

22/01 2014

2.0.0

2.0.0.0 https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader

04/03 2013

1.1.2

1.1.2.0 https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader

31/10 2012

1.1.1

1.1.1.0 https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader

31/10 2012

1.1.0

1.1.0.0 https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader

17/10 2012

1.0.0

1.0.0.0 https://github.com/eloquent/composer-config-reader

A light-weight component for reading Composer configuration files.

  Sources   Download

MIT

The Requires

 

The Development Requires

parser configuration composer reader