semver

Yet another Crystal library for Semantic Versioning.

Semver

Yet another Crystal library for Semantic Versioning. Its implementation is slightly different than the Crystal standard library.

Build Status

Installation

Add this to your application's shard.yml:

dependencies:
  semver:
    github: mosop/semver

Usage

require "semver"

Components

ver = Semver.parse("1.0.0-rc.1+build-794")
ver.major      # 1
ver.minor      # 0
ver.patch      # 0
ver.prerelease # "rc.1"
ver.build      # "build-794"

Comparison

Semver implements:

  • Comparable(Semver)
  • Comparable(String)
Semver.parse("1.0.0-alpha") < "1.0.0-beta" # true

Contributing

  1. Fork it ( https://github.com/mosop/semver/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Contributors

  • mosop - creator, maintainer
Repository

semver

Owner
Statistic
  • 1
  • 0
  • 0
  • 0
  • 0
  • over 7 years ago
  • July 7, 2016
License

MIT License

Links
Synced at

Sun, 24 Nov 2024 13:32:02 GMT

Languages