PHPackages                             ryanxedi/git-info - 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. ryanxedi/git-info

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

ryanxedi/git-info
=================

Access your local git branch information

v1.0.1(3y ago)0141[2 issues](https://github.com/ryanxedi/gitInfo/issues)MITPHP

Since Mar 5Pushed 3y ago1 watchersCompare

[ Source](https://github.com/ryanxedi/gitInfo)[ Packagist](https://packagist.org/packages/ryanxedi/git-info)[ RSS](/packages/ryanxedi-git-info/feed)WikiDiscussions main Synced today

READMEChangelog (2)DependenciesVersions (2)Used By (0)

[![Git Branch](https://raw.githubusercontent.com/ryanxedi/git-info/main/art/git-info.svg)](https://github.com/ryanxedi/git-info)

About gitInfo
-------------

[](#about-gitinfo)

gitInfo is a simple tool to retrieve the current branch or hash of your Laravel project:

Getting Started
---------------

[](#getting-started)

Pull in the package `composer require ryanxedi/git-info`

Make this available globally: Add this to the bottom of your `aliases` array in `config/app.php`

```
'gitInfo' => ryanxedi\gitInfo\gitInfo::class,

```

Usage
-----

[](#usage)

To return your current branch

`gitInfo::branch()`

To return your current branch's hash

`gitInfo::hash()`

Example
-------

[](#example)

Try this example blade code snippet:

Add the font-awesome CDN to your HTML header section:

```

```

Presumably, you don't want this to appear in your production environment.
You can wrap this in an @if() statement in your footer

```
@if (env('APP_ENV') != 'production')
	 {{ gitInfo::branch() }}
@endif

```

Update `'production'` to whatever you call your production environment in you `.env` file

License
-------

[](#license)

gitInfo is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).

###  Health Score

22

—

LowBetter than 21% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community10

Small or concentrated contributor base

Maturity45

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 80% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

1216d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/da56afe448c3ee701197149fa4763a39def5990011cb97ce92fc07aa1cf7b064?d=identicon)[ryanxedi](/maintainers/ryanxedi)

---

Top Contributors

[![ryanxedi](https://avatars.githubusercontent.com/u/13570095?v=4)](https://github.com/ryanxedi "ryanxedi (4 commits)")[![ClintWinter](https://avatars.githubusercontent.com/u/15218914?v=4)](https://github.com/ClintWinter "ClintWinter (1 commits)")

### Embed Badge

![Health badge](/badges/ryanxedi-git-info/health.svg)

```
[![Health](https://phpackages.com/badges/ryanxedi-git-info/health.svg)](https://phpackages.com/packages/ryanxedi-git-info)
```

###  Alternatives

[hitech/indonesia-laravel

Indonesia Laravel - Data terbaru daerah-daerah di indonesia termasuk 38 provinsi.

693.2k](/packages/hitech-indonesia-laravel)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
