PHPackages                             monstrum/gitter - 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. monstrum/gitter

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

monstrum/gitter
===============

Gitter allows you to interact in an object oriented manner with Git repositories.

0.3.0(11y ago)016BSD-2-ClausePHPPHP &gt;=5.3.0

Since Sep 19Pushed 9y ago1 watchersCompare

[ Source](https://github.com/monstrum/gitter)[ Packagist](https://packagist.org/packages/monstrum/gitter)[ Docs](https://github.com/klaussilveira/gitter)[ RSS](/packages/monstrum-gitter/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (4)Versions (9)Used By (0)

Gitter
======

[](#gitter)

[![Build Status](https://camo.githubusercontent.com/6435847a011e7f50f6ee235a7ac9c433d8e0689088f8d7a7491e7f7fab33462e/68747470733a2f2f7365637572652e7472617669732d63692e6f72672f6b6c61757373696c76656972612f6769747465722e706e67)](http://travis-ci.org/klaussilveira/gitter)

Gitter allows you to interact in an object oriented manner with Git repositories via PHP. The main goal of the library is not to replace the system `git` command, but provide a coherent, stable and performatic object oriented interface.

Most commands are sent to the system's `git` command, parsed and then interpreted by Gitter. Everything is transparent to you, so you don't have to worry about a thing.

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

[](#requirements)

- git () (tested with 1.7.5.4)

Authors and contributors
------------------------

[](#authors-and-contributors)

- [Klaus Silveira](http://www.klaussilveira.com) (Creator, developer)

License
-------

[](#license)

[New BSD license](http://www.opensource.org/licenses/bsd-license.php)

Usage
-----

[](#usage)

Gitter is very easy to use and you'll just need a few method calls to get started. For example, to create a new repository:

```
$client = new Gitter\Client;
$repository = $client->createRepository('/home/user/test');

```

Or a bare repository:

```
$client = new Gitter\Client;
$repository = $client->createRepository('/home/user/test', true);

```

Or to open an existing repository:

```
$client = new Gitter\Client;
$repository = $client->getRepository('/home/user/anothertest');

```

Both methods will return a `Repository` object, which has various methods that allow you to interact with that repository.

### Getting a list of commits

[](#getting-a-list-of-commits)

Once you get hold of the `Repository` object, you can use:

```
$commits = $repository->getCommits();
print_r($commits);

```

To get a list of various commits.

### Getting a single commit

[](#getting-a-single-commit)

Given a specific commit hash, you can find information about that commit:

```
$commit = $repository->getCommit('920be98a05');
print_r($commit);

```

### Getting statistics for repository

[](#getting-statistics-for-repository)

Statistics aggregators can be added to the repository:

```
$repository->addStatistics(array(
    new Gitter\Statistics\Contributors,
    new Gitter\Statistics\Date,
    new Gitter\Statistics\Day,
    new Gitter\Statistics\Hour
));
print_r($repository->getStatistics());

```

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community17

Small or concentrated contributor base

Maturity53

Maturing project, gaining track record

 Bus Factor2

2 contributors hold 50%+ of commits

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 ~102 days

Recently: every ~143 days

Total

7

Last Release

4368d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/39bc4ab046df5ca14cc418072f3bc35fe880fe17c8630ff3640b05caf281d5cb?d=identicon)[monstrum](/maintainers/monstrum)

---

Top Contributors

[![klaussilveira](https://avatars.githubusercontent.com/u/467729?v=4)](https://github.com/klaussilveira "klaussilveira (37 commits)")[![modess](https://avatars.githubusercontent.com/u/1116602?v=4)](https://github.com/modess "modess (15 commits)")[![bmanolov](https://avatars.githubusercontent.com/u/249664?v=4)](https://github.com/bmanolov "bmanolov (3 commits)")[![GromNaN](https://avatars.githubusercontent.com/u/400034?v=4)](https://github.com/GromNaN "GromNaN (3 commits)")[![fabpot](https://avatars.githubusercontent.com/u/47313?v=4)](https://github.com/fabpot "fabpot (2 commits)")[![cschorn](https://avatars.githubusercontent.com/u/332200?v=4)](https://github.com/cschorn "cschorn (2 commits)")[![monstrum](https://avatars.githubusercontent.com/u/6648831?v=4)](https://github.com/monstrum "monstrum (2 commits)")[![NateEag](https://avatars.githubusercontent.com/u/837719?v=4)](https://github.com/NateEag "NateEag (2 commits)")[![tobya](https://avatars.githubusercontent.com/u/325502?v=4)](https://github.com/tobya "tobya (1 commits)")[![cbourgois](https://avatars.githubusercontent.com/u/56223?v=4)](https://github.com/cbourgois "cbourgois (1 commits)")[![tomzx](https://avatars.githubusercontent.com/u/188960?v=4)](https://github.com/tomzx "tomzx (1 commits)")[![tribis](https://avatars.githubusercontent.com/u/54670?v=4)](https://github.com/tribis "tribis (1 commits)")[![siwinski](https://avatars.githubusercontent.com/u/1034024?v=4)](https://github.com/siwinski "siwinski (1 commits)")[![spantaleev](https://avatars.githubusercontent.com/u/388669?v=4)](https://github.com/spantaleev "spantaleev (1 commits)")[![h4cc](https://avatars.githubusercontent.com/u/2981491?v=4)](https://github.com/h4cc "h4cc (1 commits)")[![imdevin567](https://avatars.githubusercontent.com/u/3077341?v=4)](https://github.com/imdevin567 "imdevin567 (1 commits)")[![keradus](https://avatars.githubusercontent.com/u/2716794?v=4)](https://github.com/keradus "keradus (1 commits)")

---

Tags

gitvcs

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/monstrum-gitter/health.svg)

```
[![Health](https://phpackages.com/badges/monstrum-gitter/health.svg)](https://phpackages.com/packages/monstrum-gitter)
```

###  Alternatives

[cypresslab/gitelephant

An abstraction layer for git written in PHP

6131.0M23](/packages/cypresslab-gitelephant)[klaussilveira/gitter

Gitter allows you to interact in an object oriented manner with Git repositories.

20032.4k5](/packages/klaussilveira-gitter)

PHPackages © 2026

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