2017 © Pedro PelĂĄez
 

library git-version

PHP library to get current Git version

image

antalaron/git-version

PHP library to get current Git version

  • Saturday, January 27, 2018
  • by antalaron
  • Repository
  • 1 Watchers
  • 0 Stars
  • 36 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 5 Versions
  • 0 % Grown

The README.md

GitVersion

Tests, (*1)

PHP library to get the Git version of the project., (*2)

This library does not depend on the Git., (*3)

Installation

Open a command console, enter your project directory and execute the following command to download the latest stable version of this library:, (*4)

$ composer require antalaron/git-version

This command requires you to have Composer installed globally, as explained in the installation chapter of the Composer documentation., (*5)

Usage

To get the version:, (*6)

$gitVersion = new \Antalaron\GitVersion\GitVersion();
$gitVersion->getVersion(__DIR__);

// or static
\Antalaron\GitVersion\GitVersion::getGitVersion(__DIR__);

If no git found, then the return value is null., (*7)

There is a second $hashLenght parameter in the methods. With that, you will get the first n character of the hash., (*8)

To get the latest commit message:, (*9)

$gitVersion = new \Antalaron\GitVersion\GitVersion();
$gitVersion->getLatestCommit(__DIR__);

// or static
\Antalaron\GitVersion\GitVersion::getGitLatestCommit(__DIR__);

On error, the return value is null., (*10)

To get the latest commit object:, (*11)

$gitVersion = new \Antalaron\GitVersion\GitVersion();
$gitVersion->getLatestCommitDetails(__DIR__);

// or static
\Antalaron\GitVersion\GitVersion::getGitLatestCommitDetails(__DIR__);

License

This project is under MIT License., (*12)

The Versions

27/01 2018

dev-master

9999999-dev

PHP library to get current Git version

  Sources   Download

MIT

The Requires

  • php >=5.5.9

 

The Development Requires

27/01 2018

v1.1.0

1.1.0.0

PHP library to get current Git version

  Sources   Download

MIT

The Requires

  • php >=5.5.9

 

The Development Requires

26/01 2018

dev-latest-commit

dev-latest-commit

PHP library to get current Git version

  Sources   Download

MIT

The Requires

  • php >=5.5.9

 

The Development Requires

15/11 2017

v1.0.1

1.0.1.0

PHP library to get current Git version

  Sources   Download

MIT

The Requires

  • php >=5.5.9

 

The Development Requires

14/11 2017

v1.0.0

1.0.0.0

PHP library to get current Git version

  Sources   Download

MIT

The Requires

  • php >=5.5.9

 

The Development Requires