PHPackages                             markwalet/laravel-git-state - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. markwalet/laravel-git-state

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

markwalet/laravel-git-state
===========================

A Laravel package that gives you information about the current git state.

v1.11.2(3mo ago)8113.0k↓49.5%2MITPHPPHP ^8.2CI passing

Since Aug 2Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/markwalet/laravel-git-state)[ Packagist](https://packagist.org/packages/markwalet/laravel-git-state)[ Fund](https://www.paypal.me/markwalet)[ GitHub Sponsors](https://github.com/markwalet)[ RSS](/packages/markwalet-laravel-git-state/feed)WikiDiscussions main Synced 3d ago

READMEChangelog (10)Dependencies (24)Versions (37)Used By (2)

Laravel Git State
=================

[](#laravel-git-state)

[![Build Status](https://github.com/markwalet/laravel-git-state/workflows/tests/badge.svg)](https://github.com/markwalet/laravel-git-state/actions)[![Total Downloads](https://camo.githubusercontent.com/3975dd24f9fcb2b6278412ae24be76d723abd97935f4818810a9db5bd5401a36/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6d61726b77616c65742f6c61726176656c2d6769742d7374617465)](https://packagist.org/packages/markwalet/laravel-git-state)[![Latest Stable Version](https://camo.githubusercontent.com/5992de06b9f72d8979b4861d49db2e822374d8a2375ee48755183e0467347184/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6d61726b77616c65742f6c61726176656c2d6769742d7374617465)](https://packagist.org/packages/markwalet/laravel-git-state)[![License](https://camo.githubusercontent.com/dca5d8ae11aff30513f7f34448dcade6ce87f6daa0db29ec6cce59fd68874db7/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6d61726b77616c65742f6c61726176656c2d6769742d7374617465)](https://packagist.org/packages/markwalet/laravel-git-state)

A Laravel package that gives you information about the current git state.

Installation
------------

[](#installation)

You can install this package with composer:

```
composer require markwalet/laravel-git-state
```

The package supports PHP 8.2+ and Laravel 12+.

Laravel auto-loads service providers for you, so you don't have to register it. If you want to register the service provider manually, add the following line to your `config/app.php` file:

```
MarkWalet\GitState\GitStateServiceProvider::class
```

Usage
-----

[](#usage)

When you want to get information about the current git state, you can inject the `MarkWalet\GitState\Drivers\GitDriver` class in your methods:

```
