Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kherge-archive/php-version
A library for creating, editing, and comparing semantic versioning numbers.
https://github.com/kherge-archive/php-version
Last synced: 10 days ago
JSON representation
A library for creating, editing, and comparing semantic versioning numbers.
- Host: GitHub
- URL: https://github.com/kherge-archive/php-version
- Owner: kherge-archive
- License: mit
- Archived: true
- Created: 2013-05-12T23:15:59.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2014-08-10T03:40:13.000Z (over 10 years ago)
- Last Synced: 2024-05-22T15:05:58.913Z (6 months ago)
- Language: PHP
- Size: 281 KB
- Stars: 116
- Watchers: 8
- Forks: 18
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Version
=======[![Build Status]](http://travis-ci.org/herrera-io/php-version)
Version is a library for creating, editing, and comparing semantic version
numbers. Currently, v2.0.0 of the [Semantic Versioning][] specification
is supported.```php
use Herrera\Version\Dumper;
use Herrera\Version\Parser;$builder = Parser::toBuilder('1.2.3-alpha+2');
$builder->incrementMajor();
$builder->clearBuild();
$builder->clearPreRelease();echo Dumper::toString($builder); // echoes "2.0.0"
$finalVersion = $builder->getVersion();
```Documentation
-------------- [Installing][]
- Usage
- [Building][]
- [Comparing][]
- [Dumping][]
- [Parsing][]
- [Validating][][Build Status]: https://secure.travis-ci.org/herrera-io/php-version.png?branch=master
[Semantic Versioning]: http://semver.org/spec/v2.0.0.html
[Installing]: doc/00-Installing.md
[Building]: doc/01-Building.md
[Comparing]: doc/02-Comparing.md
[Dumping]: doc/03-Dumping.md
[Parsing]: doc/04-Parsing.md
[Validating]: doc/05-Validating.md