Reputation: 129
I'm trying to get various information (such as author, last committer, last commit msg, etc) from a list of remote git repos using Ruby. So far I can find two gems for the task, Grit and Ruby-git, and Ruby-git seems to be better at handling remote repos.
However, I am wondering if it is possible to get such information without fetching each of the repo first? The list I'm working on can get very long, thus fetching all of them doesn't seem to be a feasible choice.
Upvotes: 3
Views: 191
Reputation: 4633
This is not a perfect solution; but it will at least reduce the amount of data being transferred if you are only interested in the latest history.
git clone --no-checkout --depth=1 <repository>
(adapt to Ruby as needed)
Upvotes: 2
Reputation: 60305
For arbitrary repos, no, but it'd be easy enough to write hooks that maintain your report at a dedicated tag -- the sample hooks send emails, it's an easy change.
Upvotes: 0