accompli / chrono
Version Control System wrapper for PHP.
Installs: 16 648
Dependents: 1
Suggesters: 0
Security: 0
Stars: 4
Watchers: 2
Forks: 3
Open Issues: 3
Requires
- php: ^5.5 || ^7.0
- symfony/process: ^2.7 || ^3.0
Requires (Dev)
- phpunit/phpunit: ^4.4
- satooshi/php-coveralls: ^1.0
README
Version Control System wrapper for PHP.
Installation using Composer
Run the following command to add the package to your composer.json:
$ composer require accompli/chrono
Usage
The Repository
class will detect which registered VCS adapter to use based on the URL of the repository.
<?php use Accompli\Chrono\Process\ProcessExecutor; use Accompli\Chrono\Repository; $repository = new Repository('https://github.com/accompli/chrono.git', '/vcs/checkout/directory', new ProcessExecutor()); $repository->getBranches(); // Returns an array with all available branches in the repository. $repository->getTags(); // Returns an array with all available tags in the repository. $repository->checkout('0.1.0'); // Creates or updates a checkout of a tag or branch in the repository directory.
Versioning
Chrono uses Semantic Versioning 2 for new versions.
Credits and acknowledgements
- Niels Nijens
- All Contributors
- Inspired by the VCS drivers of Composer.
License
Chrono is licensed under the MIT License. Please see the LICENSE file for details.