diff options
authorIvan Enderlin <ivan.enderlin@hoa-project.net>2016-10-19 16:27:31 +0200
committerIvan Enderlin <ivan.enderlin@hoa-project.net>2016-10-19 16:27:31 +0200
commit3731954ff7c02a5a0a64b48b9772ea8fa4febb6c (patch)
parent39b035da547ec4df6fdd5d59486378d385e1f5b7 (diff)
Documentation: New `README.md` file.
1 files changed, 81 insertions, 45 deletions
diff --git a/README.md b/README.md
index d8b1683..b7f87da 100644
--- a/README.md
+++ b/README.md
@@ -1,29 +1,62 @@
-Hoa is a **modular**, **extensible** and **structured** set of PHP libraries.
-Moreover, Hoa aims at being a bridge between industrial and research worlds.
-# Hoa\Consistency ![state](http://central.hoa-project.net/State/Consistency)
+<p align="center">
+ <img src="https://static.hoa-project.net/Image/Hoa.svg" alt="Hoa" width="250px" />
+<p align="center">
+ <a href="https://travis-ci.org/hoaproject/consistency"><img src="https://img.shields.io/travis/hoaproject/consistency/master.svg" alt="Build status" /></a>
+ <a href="https://coveralls.io/github/hoaproject/consistency?branch=master"><img src="https://img.shields.io/coveralls/hoaproject/consistency/master.svg" alt="Code coverage" /></a>
+ <a href="https://packagist.org/packages/hoa/consistency"><img src="https://img.shields.io/packagist/dt/hoa/consistency.svg" alt="Packagist" /></a>
+ <a href="https://hoa-project.net/LICENSE"><img src="https://img.shields.io/packagist/l/hoa/consistency.svg" alt="License" /></a>
+<p align="center">
+ Hoa is a <strong>modular</strong>, <strong>extensible</strong> and
+ <strong>structured</strong> set of PHP libraries.<br />
+ Moreover, Hoa aims at being a bridge between industrial and research worlds.
+# Hoa\Consistency
+[![Help on IRC](https://img.shields.io/badge/help-%23hoaproject-ff0066.svg)](https://webchat.freenode.net/?channels=#hoaproject)
+[![Help on Gitter](https://img.shields.io/badge/help-gitter-ff0066.svg)](https://gitter.im/hoaproject/central)
This library provides a thin layer between PHP VMs and libraries to ensure
consistency accross VM versions and library versions.
+[Learn more](https://central.hoa-project.net/Documentation/Library/Consistency).
## Installation
-With [Composer](http://getcomposer.org/), to include this library into your
-dependencies, you need to require
+With [Composer](https://getcomposer.org/), to include this library into
+your dependencies, you need to
+require [`hoa/consistency`](https://packagist.org/packages/hoa/consistency):
- "require": {
- "hoa/consistency": "~1.0"
- }
+$ composer require hoa/consistency '~1.0'
+For more installation procedures, please read [the Source
+## Testing
+Before running the test suites, the development dependencies must be installed:
+$ composer install
+Then, to run all the test suites:
+$ vendor/bin/hoa test:run
-Please, read the website to [get more informations about how to
+For more information, please read the [contributor
## Quick usage
@@ -36,28 +69,6 @@ autoloader](http://www.php-fig.org/psr/psr-4/) and the xcallable API.
The `Hoa\Consistency\Consistency` class ensures foreward and backward
-#### Example with traits
-For instance, it provides a [`trait_exists`](http://php.net/trait_exists)
-function if it does not exist. This way, you are able to anticipate this new
-feature even if your current PHP version does not support it:
-if (trait_exists('Foo')) { …
-Also, we are able to build a complete
-`Hoa\Consistency\Consistency::entityExists` method that checks whether any kind
-of entity (class, interface or trait) exists. Even if your current PHP version
-does not support traits, it will work. And when you will upgrade, the new check
-will be free:
-if (false === Hoa\Consistency\Consistency::entityExist('foo')) {
- // load it.
#### Example with keywords
The `Hoa\Consistency\Consistency::isKeyword` checks whether a specific word is
@@ -146,9 +157,9 @@ $baz = new Foo\Bar\Baz(); // automatically loaded!
Xcallables are “extended callables”. It is a unified API to invoke callables of
any kinds, and also extends some Hoa's API (like
-[`Hoa\Stream`](http://central.hoa-project.net/Resource/Library/Stream)). It
+[`Hoa\Stream`](https://central.hoa-project.net/Resource/Library/Stream)). It
understands the following kinds:
* `'function'` as a string,
* `'class::method'` as a string,
@@ -230,10 +241,35 @@ on the `hoa://Event/Exception` event channel.
## Documentation
-Different documentations can be found on the website:
+[hack book of `Hoa\Consistency`](https://central.hoa-project.net/Documentation/Library/Consistency)
+contains detailed information about how to use this library and how it works.
+To generate the documentation locally, execute the following commands:
+$ composer require --dev hoa/devtools
+$ vendor/bin/hoa devtools:documentation --open
+More documentation can be found on the project's website:
+## Getting help
+There are mainly two ways to get help:
+ * On the [`#hoaproject`](https://webchat.freenode.net/?channels=#hoaproject)
+ IRC channel,
+ * On the forum at [users.hoa-project.net](https://users.hoa-project.net).
+## Contribution
+Do you want to contribute? Thanks! A detailed [contributor
+guide](https://hoa-project.net/Literature/Contributor/Guide.html) explains
+everything you need to know.
## License
-Hoa is under the New BSD License (BSD-3-Clause). Please, see
+Hoa is under the New BSD License (BSD-3-Clause). Please, see
+[`LICENSE`](https://hoa-project.net/LICENSE) for details.