PHPackages                             gaiththewolf/git-manager - 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. gaiththewolf/git-manager

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

gaiththewolf/git-manager
========================

this package can execute and parse git commands on project, it can provide a way to update laravel app with button click from client interface without knowing git commands

v0.0.4(3y ago)017MITPHPPHP ~8.0

Since Jun 13Pushed 3y ago1 watchersCompare

[ Source](https://github.com/mr-wolf-gb/git-manager)[ Packagist](https://packagist.org/packages/gaiththewolf/git-manager)[ Docs](https://github.com/gaiththewolf/git-manager)[ RSS](/packages/gaiththewolf-git-manager/feed)WikiDiscussions main Synced 2d ago

READMEChangelog (3)Dependencies (4)Versions (5)Used By (0)

Description
===========

[](#description)

[![Latest Version on Packagist](https://camo.githubusercontent.com/5b4ca78fe4256b5d67955df76733a5bddd8106d54d01f9420e611e2629d7e1d8/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6761697468746865776f6c662f6769742d6d616e616765722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gaiththewolf/git-manager)[![Total Downloads](https://camo.githubusercontent.com/f08140db590c1c8cdfbae95e08e49cc141deb8b910c302a2409bdb4435b96f33/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6761697468746865776f6c662f6769742d6d616e616765722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/gaiththewolf/git-manager)[![GitHub Actions](https://github.com/gaiththewolf/git-manager/actions/workflows/main.yml/badge.svg)](https://github.com/gaiththewolf/git-manager/actions/workflows/main.yml/badge.svg)

This package can execute and parse git commands on project, it can provide a way to update laravel app with button click from client interface without knowing git commands

Requirements
------------

[](#requirements)

- Laravel 9.x to 10.x
- PHP &gt;= 8.0

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

[](#installation)

You can install the package via composer:

```
composer require gaiththewolf/git-manager
```

Features
--------

[](#features)

- git version
- repository last update
- check reposiory updates (new commits)
- pull changes
- run commands like (composer, php artisan, ...)

Usage
-----

[](#usage)

```
namespace App\Http\Controllers;

use GitManager;

class UpdaterController extends Controller
{

    public function __construct()
    {
        // init and set git working directory
        GitManager::init(base_path());
    }

    public function index()
    {
        $version = GitManager::version(); // get string of installed git version
        $version = trim(str_replace("git version", "",$version));

        $lastUpdate = trim(GitManager::lastUpdate()); // get string of last update datetime

        $status = GitManager::status(); // get Object git status include command `git fetch` before
        //$status = GitManager::status("ssh password");

        $logs = GitManager::log(); // get Object Last 10 logs

        return view('update.index', compact('version', 'lastUpdate', 'status', 'logs'));
    }

    public function pull()
    {
        $output = GitManager::pull(); // get Object of pull changes if exist
        //$output = GitManager::pull("ssh password");
        if ($output["is_up_to_date"]) {
            return redirect()->route('update.index');
        }
        return redirect()->route('update.index')->with("pullData", $output);
    }

}
```

Data structure
--------------

[](#data-structure)

Data structure of `GitManager::status()`.

```
Gaiththewolf\GitManager\Data\GitStatus {#1512 ▼ // app\Http\Controllers\UpdaterController.php:37
  +branch: "main"
  +isUpToDate: true
  +isPush: false
  +isPull: false
}
```

Data structure of `GitManager::log()`.

```
Illuminate\Support\Collection {#1512 ▼ // app\Http\Controllers\UpdaterController.php:37
  #items: array:4 [▶
    0 => Gaiththewolf\GitManager\Data\GitLog {#763 ▶
      +hash: "1c1efa505bb1c15f6bc40747f3d73"
      +merge: array:2 [▶
        0 => "d0f83"
        1 => "5f047"
      ]
      +author: array:2 [▶
        "full_name" => "User 1"
        "email" => "user1@mail.local"
      ]
      +date: "Tue Jun 13 14:30:35 2023 +0100"
      +message: "Merge branch 'main' of github.com:gaiththewolf/projectXXX"
    }
    1 => Gaiththewolf\GitManager\Data\GitLog {#778 ▶
      +hash: "d0f6283eebb28d4fbc9231d3e4d6e2720cd9"
      +merge: []
      +author: array:2 [▶
        "full_name" => "User 1"
        "email" => "user1@mail.local"
      ]
      +date: "Tue Jun 13 14:30:27 2023 +0100"
      +message: "fix"
    }
    2 => Gaiththewolf\GitManager\Data\GitLog {#1579 ▶
      +hash: "5f23047507e41a429ca2a7adadcfd127"
      +merge: []
      +author: array:2 [▶
        "full_name" => "User 2"
        "email" => "user2@mail.local"
      ]
      +date: "Tue Jun 13 14:29:50 2023 +0100"
      +message: "Update README.md"
    }
    3 => Gaiththewolf\GitManager\Data\GitLog {#780 ▶
      +hash: "5160f64d7ad207322cde61bd965c2ad3a"
      +merge: []
      +author: array:2 [▶
        "full_name" => "User 1"
        "email" => "user1@mail.local"
      ]
      +date: "Tue Jun 13 14:07:35 2023 +0100"
      +message: "Update README.md"
    }
  ]
  #escapeWhenCastingToString: false
}
```

Data structure of `GitManager::pull()`.

```
Gaiththewolf\GitManager\Data\GitPull {#1512 ▼ // app\Http\Controllers\UpdaterController.php:37
  +files: array:1 [▶
    0 => " README.md"
  ]
  +isUpToDate: false
  +changed: "1"
  +insertion: "2"
  +deletion: "0"
}
```

### Testing

[](#testing)

```
composer test
```

### Changelog

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Mr.Wolf](https://github.com/gaiththewolf)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity42

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% 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

4

Last Release

1116d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/15419351feb134ab8ee8e00c4bab3be9f71f32c171a747c9ed6c2ada4d04d772?d=identicon)[gaiththewolf](/maintainers/gaiththewolf)

---

Top Contributors

[![mr-wolf-gb](https://avatars.githubusercontent.com/u/4011175?v=4)](https://github.com/mr-wolf-gb "mr-wolf-gb (11 commits)")

---

Tags

laravelgithubgitgit loggit-managergit fetchgit pullgit statusgit command parser

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/gaiththewolf-git-manager/health.svg)

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

###  Alternatives

[laravel/horizon

Dashboard and code-driven configuration for Laravel queues.

4.2k95.4M307](/packages/laravel-horizon)[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[spatie/laravel-export

Create a static site bundle from a Laravel app

674146.0k6](/packages/spatie-laravel-export)[renatomarinho/laravel-page-speed

Laravel Page Speed

2.5k1.7M10](/packages/renatomarinho-laravel-page-speed)[illuminate/process

The Illuminate Process package.

44869.2k99](/packages/illuminate-process)[laravelplus/laravel-updater

A Laravel package for syncing with upstream repositories (GitHub, GitLab, Bitbucket, etc.)

222.0k](/packages/laravelplus-laravel-updater)

PHPackages © 2026

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