Get support for fabpot/gitter
If you're new to LTH, please see our FAQ for more information on what it is we do.
Support Options
Unfortunately, there are currently no active helpers for this repository on the platform. Until they become available, we reccomend the following actions:
View Open IssuesTake a look to see if anyone else has experienced the same issue as you and if they managed to solve it.
Open an IssueMake sure to read any relevant guidelines for opening issues on this repo before posting a new issue.
Sponsor directlyCheck out the page and see if there are any options to sponsor this project or it's developers directly.
fabpot/gitter
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
- git (http://git-scm.com) (tested with 1.7.5.4)
Authors and contributors
- Klaus Silveira (Creator, developer)
License
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
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
Given a specific commit hash, you can find information about that commit:
$commit = $repository->getCommit('920be98a05');
print_r($commit);
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());
Our Mission
We want to make open source more sustainable. The entire platform was born from this and everything we do is in aid of this.
From the Blog
Interesting Articles
-
Generating income from open source
Jun 23 • 8 min read
-
2023 State of OSS
Apr 23 • 45 min read ★
-
A funding experiment...
Aug 19 • 10 min read
-
But You Said I could
Aug 19 • 2 min read
Thank you for checking out LiveTechHelper |
2025 © lth-dev incorporated
p-e622a1a2