From: Dan Brook Date: Sat, 3 Jul 2010 15:48:44 +0000 (+0100) Subject: Bumped version and added bootstrap docs. X-Git-Tag: 0.002002~4 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FGitalist.git;a=commitdiff_plain;h=faafb966f2afe724fd7608e62b0b38d0e226a53f Bumped version and added bootstrap docs. Not only can this dist be bootstrapped I've even documented how to do it. Also fixed up tabs that had crept into a couple of files. --- diff --git a/Changes b/Changes index d831856..47dfc15 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,6 @@ This file documents the revision history for Perl extension Gitalist. +0.002001 2010-07-03 - Fix for loadCommitInfo. - Fix tests to work with local-libbery. - Correct example link and FCGI script. @@ -7,6 +8,7 @@ This file documents the revision history for Perl extension Gitalist. - Throttle the commit info loading. - Update bootstrapping for local::lib 1.006000. - Fixed author_* barewords in Makefile.PL. + - Handle merges in the diff view. 0.001008 2010-06-03 - Add a requires_external_bin for the git command so we won't try running diff --git a/README b/README index 4564aaa..95fec81 100644 --- a/README +++ b/README @@ -46,6 +46,25 @@ GETTING GITALIST Gitalist is also mirrored to github, and a number of people have active forks with branches and/or new features in the master branch. +BOOTSTRAPPING + As of 0.002001 Gitalist can now be bootstrapped to run out of its own + directory by installing its prerequisites locally with the help of + local::lib. So instead of installing the prerequisites to the system + path with CPAN they are installed under the Gitalist directory. + + To do this clone Gitalist from the Shadowcat repository mentioned above + or grab a download from CPAN or broquaint's github repository: + + http://github.com/broquaint/Gitalist/downloads + + With the source acquired and unpacked run the following from within the + Gitalist directory: + + perl script/bootstrap + + This will install the necessary modules for the build process which in + turn installs the prerequisites locally. + INITIAL CONFIGURATION Gitalist is configured using Catalyst::Plugin::Configloader. The supplied sample configuration is in Config::General format, however it diff --git a/lib/Gitalist.pm b/lib/Gitalist.pm index 13a50ae..36f7098 100644 --- a/lib/Gitalist.pm +++ b/lib/Gitalist.pm @@ -14,7 +14,7 @@ use Catalyst qw/ SubRequest /; -our $VERSION = '0.001008'; +our $VERSION = '0.002001_01'; $VERSION = eval $VERSION; __PACKAGE__->config( @@ -113,6 +113,26 @@ The canonical repository for the master branch is: Gitalist is also mirrored to github, and a number of people have active forks with branches and/or new features in the master branch. +=head1 BOOTSTRAPPING + +As of C<0.002001> Gitalist can now be bootstrapped to run out of its +own directory by installing its prerequisites locally with the help of +L. So instead of installing the prerequisites to the +system path with CPAN they are installed under the Gitalist directory. + +To do this clone Gitalist from the Shadowcat repository mentioned +above or grab a download from CPAN or broquaint's github repository: + + http://github.com/broquaint/Gitalist/downloads + +With the source acquired and unpacked run the following from within the +Gitalist directory: + + perl script/bootstrap + +This will install the necessary modules for the build process which in +turn installs the prerequisites locally. + =head1 INITIAL CONFIGURATION Gitalist is configured using L. The supplied sample diff --git a/lib/Gitalist/Controller/Fragment/Ref.pm b/lib/Gitalist/Controller/Fragment/Ref.pm index 97ef77b..50788f7 100644 --- a/lib/Gitalist/Controller/Fragment/Ref.pm +++ b/lib/Gitalist/Controller/Fragment/Ref.pm @@ -131,10 +131,10 @@ after file_commit_info => sub { my $json_obj = !$commit ? { } : { - sha1 => $commit->sha1, - comment => $c->stash->{short_cmt}->($commit->comment), - age => $c->stash->{time_since}->($commit->authored_time), - }; + sha1 => $commit->sha1, + comment => $c->stash->{short_cmt}->($commit->comment), + age => $c->stash->{time_since}->($commit->authored_time), + }; $c->response->content_type('application/json'); # XXX Make use of the json branch diff --git a/lib/Gitalist/Git/Object/Commit.pm b/lib/Gitalist/Git/Object/Commit.pm index a192d0f..dde3220 100644 --- a/lib/Gitalist/Git/Object/Commit.pm +++ b/lib/Gitalist/Git/Object/Commit.pm @@ -60,11 +60,11 @@ class Gitalist::Git::Object::Commit ( $filename ? ('--', $filename) : () ), ); - # If we're not comparing against something and we have multiple - # parents then it's a merge commit so show what was merged. - my $sha1 = $parent && $parent eq '-c' && @{[$self->parents]} > 1 - ? sprintf("%s^1..%s^2", ($self->sha1) x 2) - : $self->sha1; + # If we're not comparing against something and we have multiple + # parents then it's a merge commit so show what was merged. + my $sha1 = $parent && $parent eq '-c' && @{[$self->parents]} > 1 + ? sprintf("%s^1..%s^2", ($self->sha1) x 2) + : $self->sha1; my @out = $self->_raw_diff( ( $patch ? '--patch-with-raw' : () ),