Skip to content
This repository has been archived by the owner on Dec 14, 2022. It is now read-only.
/ git-version Public archive

A helper to get the current GIT version of the application

License

Notifications You must be signed in to change notification settings

gomzyakov/git-version

Repository files navigation

GIT version getter

A helper class to get the current GIT version of the project.

Installation

Require it in your project:

composer require gomzyakov/git-version

Use

Everything is very simple. You can get the git version string with:

$version = \Gomzyakov\GitVersion\GitVersion::getVersion();

Recommended usage pattern

Ensure your git tags are pushed to your servers so that the versions are described properly.

During development and possibly in staging environments allow the version to be determined automatically (this is done via git describe).

Support

If you find any package errors, please, make an issue in current repository.

License

This is open-sourced software licensed under the MIT License.