App::KGB::Client::Git(3pm) | User Contributed Perl Documentation | App::KGB::Client::Git(3pm) |
App::KGB::Client::Git - Git support for KGB client
my $c = App::KGB::Client::Git->new({
...
git_dir => '/some/where', # defaults to
$ENV{GIT_DIR}
old_rev => 'a7c42f58',
new_rev => '8b37ed8a', });
App::KGB::Client::Git provides KGB client with knowledge about Git repositories. Its method returns a series of App::KGB::Commit objects, each corresponding to the next commit of the received series.
Input data can be given in any of the following ways:
# a single commit my $c = App::KGB::Client::Git->new({ old_rev => '9ae45bc', new_rev => 'a04d3ef', refname => 'master', });
# several commits my $c = App::KGB::Client::Git->new({ changesets => [ [ '4b3d756', '62a7c8f', 'master' ], [ '7a2fedc', '0d68c3a', 'my' ], ... ], });
All the other ways to supply the changes data is converted internally to this one.
The file must contain three words separated by spaces on each line. The first one is taken to be the old revision, the second is the new revision and the third is the refname.
In all of the above methods, the location of the .git directory can be given in the git_dir parameter, or it will be taken from the environment variable GIT_DIR.
The following parameters can be set in the "[kgb]" section of git-config(1). If present, they override the settings in the configuration file and these given on the command line.
See "project-id" in App::KGB::Client for details.
The default value is 20.
The default is ${{module} }${{branch} }${{commit} }${{author-name} }${{log}}.
The default value is 5.
The default is ${{module} }${{author-name} }${{log}}.
The default is "true".
Copyright (c) 2009, 2013 Damyan Ivanov
Based on the shell post-receive hook by Andy Parkins
This file is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
2019-01-03 | perl v5.28.1 |