Thread: [Codestriker-commits] CVS update: codestriker CHANGELOG
Brought to you by:
sits
From: <si...@us...> - 2004-12-07 21:47:23
|
User: sits Date: 04/12/07 13:47:11 Modified: . CHANGELOG Log: Updated CHANGELOG for 1.8.5 release Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.155 retrieving revision 1.156 diff -u -r1.155 -r1.156 --- CHANGELOG 21 Nov 2004 05:00:04 -0000 1.155 +++ CHANGELOG 7 Dec 2004 21:47:09 -0000 1.156 @@ -3,6 +3,12 @@ Version 1.8.5 +* Complete support for VSS repositories. Topics linked to a VSS + repository can now be created by either specifying labels with the + VSS directory of interest for code already committed in the + repository, or pre-commit reviews can be done by generating diff + text with the ssdiff.pl script in the Codestriker bin directory. + * Modified log_accum.pl so that deleted files are also included in the topic. @@ -23,7 +29,7 @@ * Added new configuration variable @Codestriker::exclude_file_types which contains a list of filename extensions which Codestriker will - ignore when creatign topics. These generally include those + ignore when creating topics. These generally include those extensions which are binary, or of not any interest. Contributed by Dave Clendenan <dav...@po...>. |
From: <si...@us...> - 2005-02-14 09:45:35
|
Created Codestriker topic at: http://codestriker.sourceforge.net/cgi-bin/codestriker.pl?topic=1639770&action=view User: sits Date: 05/02/14 01:45:19 Modified: . CHANGELOG Log: Fixed speeling Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.162 retrieving revision 1.163 diff -u -r1.162 -r1.163 --- CHANGELOG 14 Feb 2005 09:43:46 -0000 1.162 +++ CHANGELOG 14 Feb 2005 09:45:18 -0000 1.163 @@ -19,7 +19,7 @@ * Added RSS support, so that the topic list screen now has an equivalent RSS view. From Jason Remillard. -* Optimised database ocnnection code, from Jason Remillard. +* Optimised database connection code, from Jason Remillard. * Added a "add other reviewers" link next to the Cc: field in the "add comment" screen. This allows the comment author to easily Cc all |
From: <si...@us...> - 2005-02-16 23:31:40
|
Created Codestriker topic at: http://codestriker.sourceforge.net/cgi-bin/codestriker.pl?topic=7473208&action=view User: sits Date: 05/02/16 15:31:24 Modified: . CHANGELOG Log: Updated CHANGELOG Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.166 retrieving revision 1.167 diff -u -r1.166 -r1.167 --- CHANGELOG 16 Feb 2005 11:54:23 -0000 1.166 +++ CHANGELOG 16 Feb 2005 23:31:21 -0000 1.167 @@ -49,9 +49,12 @@ * When creating new topics linked to Bugzilla, also include the topic description field in the Bugzilla comment. -* Searching on the bugid and cc fields was not working ocrrectly. +* Searching on the bugid and cc fields was not working correctly. This has now been fixed. +* On UNIX platforms, missing modules can be fetched and installed + automatically using the CPAN module, if required. + Version 1.8.5 * Complete support for VSS repositories. Topics linked to a VSS |
From: <si...@us...> - 2005-06-19 22:54:31
|
Created Codestriker topic at: http://codestriker.sourceforge.net/cgi-bin/codestriker.pl?topic=7304969&action=view User: sits Date: 05/06/19 15:54:11 Modified: . CHANGELOG Log: Added changelog note about new svn config variable Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.172 retrieving revision 1.173 diff -u -r1.172 -r1.173 --- CHANGELOG 19 Jun 2005 10:55:54 -0000 1.172 +++ CHANGELOG 19 Jun 2005 22:54:10 -0000 1.173 @@ -96,6 +96,10 @@ * Filenames ending in ++, for example, filename.c++ could not be loaded into the system, due to a bug introduced in 1.8.5. +* Added $svn configuration variable to codestriker.conf, so that the + path to the subversion executable can be specified, which is often a + requirement for Win32 systems. + Version 1.8.5 * Complete support for VSS repositories. Topics linked to a VSS |
From: <si...@us...> - 2006-06-09 03:23:04
|
User: sits Date: 06/06/08 20:20:03 Modified: lib/Codestriker/Model Comment.pm . CHANGELOG Log: * Defining new entries in $comment_state_metrics in codestriker.conf could not be used for existing topics. This has now been fixed. Index: Comment.pm =================================================================== RCS file: /cvsroot/codestriker/codestriker/lib/Codestriker/Model/Comment.pm,v retrieving revision 1.22 retrieving revision 1.23 diff -u -r1.22 -r1.23 --- Comment.pm 26 May 2006 05:42:49 -0000 1.22 +++ Comment.pm 9 Jun 2006 03:20:02 -0000 1.23 @@ -412,12 +412,7 @@ 'modified_ts = ? ' . 'WHERE id = ?'); - my $update_metrics = - $dbh->prepare_cached('UPDATE commentstatemetric SET value = ? ' . - 'WHERE id = ? AND name = ?'); - - my $success = defined $select_comments && defined $update_comments - && defined $update_metrics; + my $success = defined $select_comments && defined $update_comments; my $rc = $Codestriker::OK; # Retrieve the current comment data. @@ -443,15 +438,17 @@ $rc = $Codestriker::STALE_VERSION; } - # Now update the version number for ocmmentstate, and the metric - # record itself. + # Now update the version number for commentstate. $self->{version} = $self->{version} + 1; $self->{metrics}->{$metric_name} = $metric_value; $self->{modified_ts} = Codestriker->format_timestamp($timestamp); $success &&= $update_comments->execute($self->{version}, $timestamp, $id); - $success &&= $update_metrics->execute($metric_value, $id, $metric_name); + + # Now update the commentstatemetric row for this metric. + my $metrics = [ { name => $metric_name, value => $metric_value } ]; + update_comment_metrics($id, $metrics, $dbh); Codestriker::DB::DBI->release_connection($dbh, $success); Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.188 retrieving revision 1.189 diff -u -r1.188 -r1.189 --- CHANGELOG 7 Jun 2006 00:00:57 -0000 1.188 +++ CHANGELOG 9 Jun 2006 03:20:03 -0000 1.189 @@ -66,6 +66,9 @@ case insensitive to account for the different casing returned by the Window clients: Cygwin and CvsNT. +* Defining new entries in $comment_state_metrics in codestriker.conf + could not be used for existing topics. This has now been fixed. + Version 1.9.1 * Correct problem introduced in 1.9.0 release where the email address |
From: <si...@us...> - 2007-03-07 03:06:26
|
User: sits Date: 07/03/06 19:06:25 Modified: . CHANGELOG Log: Updated CHANGELOG Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.198 retrieving revision 1.199 diff -u -r1.198 -r1.199 --- CHANGELOG 7 Mar 2007 01:12:31 -0000 1.198 +++ CHANGELOG 7 Mar 2007 03:06:25 -0000 1.199 @@ -17,6 +17,9 @@ which was responsible for generating invalid links. This has now been fixed. +* Better handling of parsing Subversion diffs which were generated on + non-English systems. + Version 1.9.2 * Codestriker now works with UTF-8 text, to support unicode character |
From: <si...@us...> - 2007-08-18 04:15:50
|
User: sits Date: 07/08/17 21:15:46 Modified: . CHANGELOG Log: Last commit was for: * When calculating metrics, make sure email addresses are handled in a case-insensitive manner. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.210 retrieving revision 1.211 diff -u -r1.210 -r1.211 --- CHANGELOG 3 Jul 2007 11:07:50 -0000 1.210 +++ CHANGELOG 18 Aug 2007 04:15:46 -0000 1.211 @@ -35,6 +35,16 @@ * Handle Subversion files which contain @ in the filename. +* Codestriker now behaves correctly under mod_perl when retrieving + data externally from an SCM system, such as when the Parallel link + is clicked, or when a topic is created directly from the SCM. + +* Creating Subversion topics directly from the SCM now works correctly + in non-English locales. + +* When calculating metrics, make sure email addresses are handled in + a case-insensitive manner. + Version 1.9.3 * The project list screen now displays for each project, the total |
From: <si...@us...> - 2008-01-10 21:48:34
|
User: sits Date: 08/01/10 13:48:34 Modified: . CHANGELOG Log: Updated changelog Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.220 retrieving revision 1.221 diff -u -r1.220 -r1.221 --- CHANGELOG 9 Jan 2008 06:16:05 -0000 1.220 +++ CHANGELOG 10 Jan 2008 21:48:34 -0000 1.221 @@ -7,6 +7,9 @@ and a revision number (for the start or end tag) to create a review for a specific version of a file in a subversion repository. +* Fixed database code which was preventing user metrics being updated + under SQL Server. + * Make sure the email subject field properly encodes underscores and question marks. Submitted by jo...@us.... |
From: <si...@us...> - 2008-06-16 07:37:09
|
User: sits Date: 08/06/16 00:37:07 Modified: . CHANGELOG Log: Updated to reflect new LXR rendering code. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.227 retrieving revision 1.228 diff -u -r1.227 -r1.228 --- CHANGELOG 13 Jun 2008 05:55:13 -0000 1.227 +++ CHANGELOG 16 Jun 2008 07:37:07 -0000 1.228 @@ -37,7 +37,8 @@ * Added support for LXR 0.9.5, which renamed the database tables to contain an lxr_ prefix by default. Support for older LXR databases - will still work by default. + will still work by default. LXR entities are now rendered in black text, + the same as program code, but an underline is shown when hovered over. Version 1.9.4 |
From: <si...@us...> - 2008-06-17 06:51:40
|
User: sits Date: 08/06/16 23:51:38 Modified: lib/Codestriker/FileParser SubversionDiff.pm . CHANGELOG Log: * Updated the Subversion diff parser so that it correctly identifies new files, rather than treating them as modified files. Index: SubversionDiff.pm =================================================================== RCS file: /cvsroot/codestriker/codestriker/lib/Codestriker/FileParser/SubversionDiff.pm,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- SubversionDiff.pm 18 Aug 2007 04:54:08 -0000 1.8 +++ SubversionDiff.pm 17 Jun 2008 06:51:37 -0000 1.9 @@ -113,7 +113,7 @@ # Try and read the base revision this change is against, # while handling new and removed files. my $base_revision = -1; - if ($line =~ /^\-\-\- .*\s.* (\d+)/io) { + if ($line =~ /^\-\-\- .*\s.*\(.*?(\d+)\)/io) { $base_revision = $1; } elsif ($line !~ /^\-\-\- .*/io) { return (); Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.228 retrieving revision 1.229 diff -u -r1.228 -r1.229 --- CHANGELOG 16 Jun 2008 07:37:07 -0000 1.228 +++ CHANGELOG 17 Jun 2008 06:51:38 -0000 1.229 @@ -38,7 +38,10 @@ * Added support for LXR 0.9.5, which renamed the database tables to contain an lxr_ prefix by default. Support for older LXR databases will still work by default. LXR entities are now rendered in black text, - the same as program code, but an underline is shown when hovered over. + the same as program code, but an underline is shown when hovered over. + +* Updated the Subversion diff parser so that it correctly identifies new + files, rather than treating them as modified files. Version 1.9.4 |
From: <si...@us...> - 2008-06-18 07:11:55
|
User: sits Date: 08/06/18 00:11:51 Modified: . CHANGELOG Log: Update changelog to indicate highlighting has been implemented. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.229 retrieving revision 1.230 diff -u -r1.229 -r1.230 --- CHANGELOG 17 Jun 2008 06:51:38 -0000 1.229 +++ CHANGELOG 18 Jun 2008 07:11:50 -0000 1.230 @@ -3,6 +3,12 @@ Version 1.9.5 +* Syntax highlighting is now supported using the highlight package from + http://www.andre-simon.de/. Check the codestriker.conf file for + configuration. Many thanks to Nikita V. Borodikhin + <el...@us...> for all his assistance in implementing + this feature. + * Allow the ability to specify just a filename (for the module field) and a revision number (for the start or end tag) to create a review for a specific version of a file in a subversion repository. |
From: <si...@us...> - 2008-06-20 05:55:45
|
User: sits Date: 08/06/19 22:55:44 Modified: . CHANGELOG Log: Updated with Perforce change. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.231 retrieving revision 1.232 diff -u -r1.231 -r1.232 --- CHANGELOG 19 Jun 2008 03:33:51 -0000 1.231 +++ CHANGELOG 20 Jun 2008 05:55:44 -0000 1.232 @@ -52,6 +52,12 @@ * Removed the "View with minimal screen width" / "View with minimal link break" options from the view topic screen. If the browser window is not wide enough, lines will wrap if possible. + +* Provided the ability to create topics for a specific changeset from + a Perforce repository, from Alis McCutcheon <amc...@nx...>. + For example, //depot/src/tools/unittests/python/ can be set + as the module name, and 12736 (the changeset number) can be set + in either the start or end tag field. Version 1.9.4 |
From: <si...@us...> - 2008-06-22 11:28:04
|
User: sits Date: 08/06/21 04:10:41 Modified: . CHANGELOG Log: * Added a new CSS file as a part of the distribution which provides a bluish scheme, called codestriker-bluish.css is the html directory. This CSS file can be set from within codestriker.conf and was contributed by Kannan Goundan <ca...@us...>. The ability to easily change which CSS file to use was submitted by rob...@us.... Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.232 retrieving revision 1.233 diff -u -r1.232 -r1.233 --- CHANGELOG 20 Jun 2008 05:55:44 -0000 1.232 +++ CHANGELOG 21 Jun 2008 11:10:41 -0000 1.233 @@ -58,6 +58,13 @@ For example, //depot/src/tools/unittests/python/ can be set as the module name, and 12736 (the changeset number) can be set in either the start or end tag field. + +* Added a new CSS file as a part of the distribution which provides a + bluish scheme, called codestriker-bluish.css is the html directory. + This CSS file can be set from within codestriker.conf and was + contributed by Kannan Goundan <ca...@us...>. + The ability to easily change which CSS file to use was submitted by + rob...@us.... Version 1.9.4 |
From: <si...@us...> - 2008-06-23 22:44:04
|
User: sits Date: 08/06/23 15:44:03 Modified: . CHANGELOG Log: Updated to reflect CSS work. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.233 retrieving revision 1.234 diff -u -r1.233 -r1.234 --- CHANGELOG 21 Jun 2008 11:10:41 -0000 1.233 +++ CHANGELOG 23 Jun 2008 22:44:03 -0000 1.234 @@ -59,12 +59,9 @@ as the module name, and 12736 (the changeset number) can be set in either the start or end tag field. -* Added a new CSS file as a part of the distribution which provides a - bluish scheme, called codestriker-bluish.css is the html directory. - This CSS file can be set from within codestriker.conf and was - contributed by Kannan Goundan <ca...@us...>. - The ability to easily change which CSS file to use was submitted by - rob...@us.... +* Updated the Codestriker CSS file significantly based on the work by + Kannan Goundan <ca...@us...>. Also changed the + appearance of the application to give it a more modern look. Version 1.9.4 |
From: <si...@us...> - 2008-06-23 23:02:45
|
User: sits Date: 08/06/23 16:02:45 Modified: . CHANGELOG Log: Indicate that comments can be added to any line. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.234 retrieving revision 1.235 diff -u -r1.234 -r1.235 --- CHANGELOG 23 Jun 2008 22:44:03 -0000 1.234 +++ CHANGELOG 23 Jun 2008 23:02:45 -0000 1.235 @@ -62,6 +62,9 @@ * Updated the Codestriker CSS file significantly based on the work by Kannan Goundan <ca...@us...>. Also changed the appearance of the application to give it a more modern look. + +* Can now comment on any line of any file in the review, not just those + that are a part of the diff file. Version 1.9.4 |
From: <si...@us...> - 2008-06-25 07:27:14
|
User: sits Date: 08/06/25 00:27:13 Modified: . CHANGELOG Log: Updated to be more accurate. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.235 retrieving revision 1.236 diff -u -r1.235 -r1.236 --- CHANGELOG 23 Jun 2008 23:02:45 -0000 1.235 +++ CHANGELOG 25 Jun 2008 07:27:12 -0000 1.236 @@ -51,7 +51,7 @@ * Removed the "View with minimal screen width" / "View with minimal link break" options from the view topic screen. If the browser window - is not wide enough, lines will wrap if possible. + is not wide enough, a horizontal scrollbar will appear. * Provided the ability to create topics for a specific changeset from a Perforce repository, from Alis McCutcheon <amc...@nx...>. |
From: <si...@us...> - 2008-07-02 00:39:56
|
User: sits Date: 08/07/01 17:39:53 Modified: . CHANGELOG Log: Fixed typo. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.238 retrieving revision 1.239 diff -u -r1.238 -r1.239 --- CHANGELOG 2 Jul 2008 00:37:00 -0000 1.238 +++ CHANGELOG 2 Jul 2008 00:39:53 -0000 1.239 @@ -60,7 +60,7 @@ in either the start or end tag field. * Updated the Codestriker CSS file significantly based on the work by - Kannan Goundan <ca...@us...> ands Daniel Noll. + Kannan Goundan <ca...@us...> and Daniel Noll. Also changed the appearance of the application to give it a more modern appearance. |
From: <si...@us...> - 2008-07-07 23:11:35
|
User: sits Date: 08/07/07 16:11:34 Modified: . CHANGELOG Log: Updated changelog to reflect that sorting of topic filenames is enabled by default. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.240 retrieving revision 1.241 diff -u -r1.240 -r1.241 --- CHANGELOG 5 Jul 2008 04:06:54 -0000 1.240 +++ CHANGELOG 7 Jul 2008 23:11:33 -0000 1.241 @@ -78,7 +78,7 @@ topic should be ordered by filename. Apparently Subversion can produce diff topics in some circumstances in arbitrary order, where using this setting would make sense. Default is for this - setting to disabled. + setting to be enabled. Version 1.9.4 |
From: <si...@us...> - 2008-07-10 10:43:59
|
User: sits Date: 08/07/10 03:43:55 Modified: bin codestriker.pl.base install.pl . CHANGELOG Log: * Fix for "v-string in use/require non-portable" warning when using Perl 5.10 from rob...@us.... Index: codestriker.pl.base =================================================================== RCS file: /cvsroot/codestriker/codestriker/bin/codestriker.pl.base,v retrieving revision 1.25 retrieving revision 1.26 diff -u -r1.25 -r1.26 --- codestriker.pl.base 22 Feb 2008 00:32:00 -0000 1.25 +++ codestriker.pl.base 10 Jul 2008 10:43:55 -0000 1.26 @@ -12,13 +12,13 @@ # This is the top level package which receives all HTTP requests, and # delegates it to the appropriate Action module. -require 5.8.0; +require 5.008_0; # Set this to the location of the Codestriker libraries on your system. # Ideally, this should be done in the apache configs, but trying to do this # in an easy way for Apache1/Apache2 with/without mod_perl with/without taint # checking turned out to be a major headache. For mod_perl, setting this -# ensures the first time Codestiker is loaded, it can be compiled properly, +# ensures the first time Codestriker is loaded, it can be compiled properly, # even if @INC is blatted later. Also note all the use declarations below # effectively "pre-load" all of the Codestriker modules in the system, as the # modules below load all of their supporting modules. That is why the Index: install.pl =================================================================== RCS file: /cvsroot/codestriker/codestriker/bin/install.pl,v retrieving revision 1.18 retrieving revision 1.19 diff -u -r1.18 -r1.19 --- install.pl 17 Jun 2008 12:00:54 -0000 1.18 +++ install.pl 10 Jul 2008 10:43:55 -0000 1.19 @@ -24,7 +24,7 @@ use Config; use lib '../lib'; -require 5.8.0; +require 5.008_0; # Now load up the required modules. Do this is a lazy fashion so that Perl # doesn't try to grab this during compile time, otherwise nasty-looking Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.241 retrieving revision 1.242 diff -u -r1.241 -r1.242 --- CHANGELOG 7 Jul 2008 23:11:33 -0000 1.241 +++ CHANGELOG 10 Jul 2008 10:43:55 -0000 1.242 @@ -6,6 +6,9 @@ * "Default to head" option for CVS topic creation was not used when selected, but when it was unselected. This has now been fixed. Spotted by mn...@us.... + +* Fix for "v-string in use/require non-portable" warning when using + Perl 5.10 from rob...@us.... Version 1.9.5 |
From: <si...@us...> - 2008-08-02 04:47:42
|
User: sits Date: 08/08/01 21:47:41 Modified: lib/Codestriker/FileParser SubversionDiff.pm UnidiffUtils.pm . CHANGELOG Added: t/FileParser subversion.t test/testtopictexts svn-PropDiff8.txt svn-PropDiff7.txt Log: * Fixed the parsing of Subversion diffs which contained modifications within property sets. Reported by cle...@us.... Also added unit tests over all subversion test topics. Index: subversion.t =================================================================== RCS file: subversion.t diff -N subversion.t --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ subversion.t 2 Aug 2008 04:47:39 -0000 1.1 @@ -0,0 +1,307 @@ +# Tests to ensure that subversion patches are handled correctly. + +use strict; +use Fatal qw / open close /; +use Test::More tests => 33; + +use lib '../../lib'; +use Codestriker::FileParser::SubversionDiff; + +assert_delta_equals('../../test/testtopictexts/svn-Propdiff1.txt', ()); +assert_delta_equals('../../test/testtopictexts/svn-Propdiff2.txt', ()); +assert_delta_equals('../../test/testtopictexts/svn-Propdiff3.txt', ()); +assert_delta_equals('../../test/testtopictexts/svn-Propdiff4.txt', + make_delta(filename => 'parseBuildLogs', + old_linenumber => 9, + new_linenumber => 9, + revision => 7, + text => <<'END_DELTA', + if [[ "${MYHOSTNAME}" == "compaq" ]]; then + DATABASEHOST="elmo"; + XMLDIR="$HOME/downloads/cruise-xml" +- else +- DATABASEHOST="webdev2"; +- XMLDIR="/export/home/buildmaster/cruisecontrol/logs" +- fi + fi + + if [ -x "/usr/bin/python2" ]; then +END_DELTA + ), + make_delta(filename => 'buildCleanup.py', + old_linenumber => 28, + new_linenumber => 28, + revision => 7, + text => <<'END_DELTA', + # GCOMDirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/GCOM'] + # EPRODirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/EPRODATA'] + +- GCOMDirectories = [ 'testdata/branches/GCOM' ] +- EPRODirectories = [ 'testdata/branches/EPRODATA' ] + +- activeGraingerBuild = database.getActiveBuild("PRD", "gcom") +- activeEPROBuild = database.getActiveBuild("PRD", "eprodata") + + print activeGraingerBuild.getBranchIdentifier() + print activeEPROBuild.getBranchIdentifier() +END_DELTA + )); + +assert_delta_equals('../../test/testtopictexts/svn-Propdiff5.txt', + make_delta(filename => 'parseBuildLogs', + old_linenumber => 9, + new_linenumber => 9, + revision => 6, + text => <<'END_DELTA', + if [[ "${MYHOSTNAME}" == "compaq" ]]; then + DATABASEHOST="elmo"; + XMLDIR="$HOME/downloads/cruise-xml" +- else +- DATABASEHOST="webdev2"; +- XMLDIR="/export/home/buildmaster/cruisecontrol/logs" +- fi + fi + + if [ -x "/usr/bin/python2" ]; then +END_DELTA + ), + make_delta(filename => 'buildCleanup.py', + old_linenumber => 28, + new_linenumber => 28, + revision => 6, + text => <<'END_DELTA', + # GCOMDirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/GCOM'] + # EPRODirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/EPRODATA'] + +- GCOMDirectories = [ 'testdata/branches/GCOM' ] +- EPRODirectories = [ 'testdata/branches/EPRODATA' ] + +- activeGraingerBuild = database.getActiveBuild("PRD", "gcom") +- activeEPROBuild = database.getActiveBuild("PRD", "eprodata") + + print activeGraingerBuild.getBranchIdentifier() + print activeEPROBuild.getBranchIdentifier() +END_DELTA + )); + +assert_delta_equals('../../test/testtopictexts/svn-Propdiff6.txt', + make_delta(filename => 'parseBuildLogs', + old_linenumber => 9, + new_linenumber => 9, + revision => 6, + text => <<'END_DELTA', + if [[ "${MYHOSTNAME}" == "compaq" ]]; then + DATABASEHOST="elmo"; + XMLDIR="$HOME/downloads/cruise-xml" +- else +- DATABASEHOST="webdev2"; +- XMLDIR="/export/home/buildmaster/cruisecontrol/logs" +- fi + fi + + if [ -x "/usr/bin/python2" ]; then +END_DELTA + ), + make_delta(filename => 'buildCleanup.py', + old_linenumber => 28, + new_linenumber => 28, + revision => 6, + text => <<'END_DELTA', + # GCOMDirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/GCOM'] + # EPRODirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/EPRODATA'] + +- GCOMDirectories = [ 'testdata/branches/GCOM' ] +- EPRODirectories = [ 'testdata/branches/EPRODATA' ] + +- activeGraingerBuild = database.getActiveBuild("PRD", "gcom") +- activeEPROBuild = database.getActiveBuild("PRD", "eprodata") + + print activeGraingerBuild.getBranchIdentifier() + print activeEPROBuild.getBranchIdentifier() +END_DELTA + )); + +assert_delta_equals('../../test/testtopictexts/svn-Propdiff7.txt', + make_delta(filename => 'users/clechasseur/local/devsetup/CoveoDevSetup.iss', + old_linenumber => 31, + new_linenumber => 31, + revision => 44307, + text => <<'END_DELTA', + + [Languages] + Name: english; MessagesFile: compiler:Default.isl ++; woo! +END_DELTA +)); + +assert_delta_equals('../../test/testtopictexts/svn-Propdiff8.txt', + make_delta(filename => 'users/clechasseur/local/devsetup/CoveoDevSetup.iss', + old_linenumber => 31, + new_linenumber => 31, + revision => 44309, + text => <<'END_DELTA', + + [Languages] + Name: english; MessagesFile: compiler:Default.isl ++; woo! +END_DELTA +)); + +assert_delta_equals('../../test/testtopictexts/svn-look-diff1.txt', + make_delta(filename => 't1.txt', + old_linenumber => 0, + new_linenumber => 1, + revision => 0, + text => <<'END_DELTA', ++line1 ++line2 ++line3 +END_DELTA +)); + +assert_delta_equals('../../test/testtopictexts/svn-look-diff2.txt', + make_delta(filename => 't1.txt', + old_linenumber => 1, + new_linenumber => 1, + revision => 89, + text => <<'END_DELTA', ++line0 + line1 + line2 ++line2.2 + line3 +END_DELTA +)); + +assert_delta_equals('../../test/testtopictexts/svn-look-diff3.txt', + make_delta(filename => 't1.txt', + old_linenumber => 1, + new_linenumber => 0, + revision => 90, + text => <<'END_DELTA', +-line0 +-line1 +-line2 +-line2.2 +-line3 +END_DELTA +)); + +assert_delta_equals('../../test/testtopictexts/svn-look-diff4.txt', + make_delta(filename => 't1.txt', + old_linenumber => 1, + new_linenumber => 1, + revision => 92, + text => <<'END_DELTA', +-l1 ++l1 ++l2 ++l3 +END_DELTA + ), + make_delta(filename => 't2.txt', + old_linenumber => 1, + new_linenumber => 0, + revision => 92, + text => <<'END_DELTA', +-l1 +END_DELTA +)); + +assert_delta_equals('../../test/testtopictexts/svn-look-diff5.txt', + make_delta(filename => 'show_user_photo.jpg', + old_linenumber => -1, + new_linenumber => -1, + text => '', + binary => 1, + ), + make_delta(filename => 't2.txt', + old_linenumber => 0, + new_linenumber => 1, + revision => 93, + text => <<'END_DELTA', ++aaa ++bbb ++ccc +END_DELTA +)); + +assert_delta_equals('../../test/testtopictexts/svn-look-diff6.txt', + make_delta(filename => 'show_user_photo.jpg', + old_linenumber => -1, + new_linenumber => -1, + text => '', + binary => 1, + ), + make_delta(filename => 't1.txt', + old_linenumber => 1, + new_linenumber => 1, + revision => 94, + text => <<'END_DELTA', + l1 ++l11 + l2 ++l22 + l3 +END_DELTA + ), + make_delta(filename => 't2.txt', + old_linenumber => 1, + new_linenumber => 0, + revision => 94, + text => <<'END_DELTA', +-aaa +-bbb +-ccc +END_DELTA + ), + make_delta(filename => 't3.txt', + old_linenumber => 0, + new_linenumber => 1, + revision => 0, + text => <<'END_DELTA', ++labuda +END_DELTA +)); + +# Convenience function for creating a delta object. +sub make_delta { + + # Set constant properties for all subversion deltas. + my $delta = {}; + $delta->{binary} = 0; + $delta->{repmatch} = 1; + $delta->{description} = ''; + + # Apply the passed in arguments. + my %arg = @_; + $delta->{filename} = $arg{filename}; + $delta->{revision} = $arg{revision}; + $delta->{old_linenumber} = $arg{old_linenumber}; + $delta->{new_linenumber} = $arg{new_linenumber}; + $delta->{text} = $arg{text}; + $delta->{binary} = $arg{binary} if exists $arg{binary}; + + return $delta; +} + +# Function for parsing the topic text, and check that the parsed deltas +# matched the expected deltas. +sub assert_delta_equals { + my $filename = shift; + my @expected = @_; + + # Open up the specified file and attempt to parse the deltas + # from it. + my $fh; + open( $fh, '<', $filename ); + my @actual = Codestriker::FileParser::SubversionDiff->parse($fh); + close($fh); + + # Check that the extracted deltas match what is expected. + is( @actual, @expected, "Number of deltas for file: $filename" ); + for ( my $index = 0; $index < @actual; $index++ ) { + is_deeply( $actual[$index], $expected[$index], + "Delta $index in file $filename" ); + } +} \ No newline at end of file Index: SubversionDiff.pm =================================================================== RCS file: /cvsroot/codestriker/codestriker/lib/Codestriker/FileParser/SubversionDiff.pm,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- SubversionDiff.pm 17 Jun 2008 06:51:37 -0000 1.9 +++ SubversionDiff.pm 2 Aug 2008 04:47:40 -0000 1.10 @@ -45,36 +45,37 @@ while ($line =~ /^.*Property changes on: .*$/o) { $line = <$fh>; return () unless defined $line && - $line =~ /^___________________________________________________________________$/o; + $line =~ /^___________________________________________________________________$/o; - # Keep reading until we either get to an Index: line, a property - # block, an Added/Deleted/Modified lines or the end of file. - while (defined $line && - $line !~ /^.*Index:/o && - $line !~ /^.*Added:/o && - $line !~ /^.*Deleted:/o && - $line !~ /^.*Modified:/o && - $line !~ /^.*Copied:/o && - $line !~ /^.*Property changes on:/o) { - $line = <$fh>; - } - - if (! defined $line) { - # End of file has been reached, return what we have parsed. - return @result; - } - } + # Keep reading until we either get to the separator line or end of file. + while (defined $line && + $line !~ /^===================================================================$/o) { + if ($line =~ /^.*(Index|Added|Modified|Copied|Deleted): (.*)$/o) { + $entry_type = $1; + $filename = $2; + } + $line = <$fh>; + } + + if (!defined $line) { + # End of file has been reached, return what we have parsed. + return @result; + } + } - return () unless - $line =~ /^.*(Index|Added|Modified|Copied|Deleted): (.*)$/o; - $entry_type = $1; - $filename = $2; - $line = <$fh>; + if ($line =~ /^.*(Index|Added|Modified|Copied|Deleted): (.*)$/o) { + $entry_type = $1; + $filename = $2; + $line = <$fh>; + } # The separator line appears next. return () unless defined $line && $line =~ /^===================================================================$/o; $line = <$fh>; + # Check if this is a file entry with no content. If so, skip it. + next if ! defined $line || $line =~ /^\s*$/o; + # Check if the delta represents a binary file. if ($line =~ /^Cannot display: file marked as a binary type\./o || $line =~ /^\(Binary files differ\)/o) { Index: UnidiffUtils.pm =================================================================== RCS file: /cvsroot/codestriker/codestriker/lib/Codestriker/FileParser/UnidiffUtils.pm,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- UnidiffUtils.pm 18 Aug 2007 04:54:08 -0000 1.6 +++ UnidiffUtils.pm 2 Aug 2008 04:47:40 -0000 1.7 @@ -52,6 +52,10 @@ if ($num_matched_old_lines >= $number_old_lines && $num_matched_new_lines >= $number_new_lines) { last unless $line =~ /^\s*$/o; + + # Consume excessive blank lines. + $line = <$fh>; + next; } else { if ($line =~ /^\-/o) { Index: svn-PropDiff8.txt =================================================================== RCS file: svn-PropDiff8.txt diff -N svn-PropDiff8.txt --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ svn-PropDiff8.txt 2 Aug 2008 04:47:40 -0000 1.1 @@ -0,0 +1,16 @@ +Index: users/clechasseur/local/devsetup/CoveoDevSetup.iss +=================================================================== +--- users/clechasseur/local/devsetup/CoveoDevSetup.iss (revision 44309) ++++ users/clechasseur/local/devsetup/CoveoDevSetup.iss (revision 44310) +@@ -31,3 +31,4 @@ + + [Languages] + Name: english; MessagesFile: compiler:Default.isl ++; woo! + +Property changes on: CoveoDevSetup.iss +___________________________________________________________________ +Added: test:foo + + bar + + Index: svn-PropDiff7.txt =================================================================== RCS file: svn-PropDiff7.txt diff -N svn-PropDiff7.txt --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ svn-PropDiff7.txt 2 Aug 2008 04:47:40 -0000 1.1 @@ -0,0 +1,19 @@ +Index: users/clechasseur/local/devsetup/CoveoDevSetup.iss +=================================================================== +--- users/clechasseur/local/devsetup/CoveoDevSetup.iss (revision 44307) ++++ users/clechasseur/local/devsetup/CoveoDevSetup.iss (revision 44308) +@@ -31,3 +31,4 @@ + + [Languages] + Name: english; MessagesFile: compiler:Default.isl ++; woo! +Index: users/clechasseur/local/devsetup/New Text Document.txt +=================================================================== + +Property changes on: New Text Document.txt +___________________________________________________________________ +Added: svn:keywords + + Id HeadURL + +Index: users/clechasseur/local/devsetup/New Text Document (2).datata +=================================================================== Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.247 retrieving revision 1.248 diff -u -r1.247 -r1.248 --- CHANGELOG 22 Jul 2008 00:57:49 -0000 1.247 +++ CHANGELOG 2 Aug 2008 04:47:41 -0000 1.248 @@ -28,6 +28,9 @@ * Scmbug integration now works correctly if multiple bug IDs are specified is the create topic screen. Fixed by rob...@us.... + +* Fixed the parsing of Subversion diffs which contained modifications + within property sets. Reported by cle...@us.... Version 1.9.5 |
From: <si...@us...> - 2008-08-02 04:49:07
|
User: sits Date: 08/08/01 21:49:07 Modified: . CHANGELOG Log: Forgot to mention how entries with empty content are also handled. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.248 retrieving revision 1.249 diff -u -r1.248 -r1.249 --- CHANGELOG 2 Aug 2008 04:47:41 -0000 1.248 +++ CHANGELOG 2 Aug 2008 04:49:07 -0000 1.249 @@ -30,7 +30,8 @@ rob...@us.... * Fixed the parsing of Subversion diffs which contained modifications - within property sets. Reported by cle...@us.... + within property sets. Also fixed case where file in diff is empty. + Reported by cle...@us.... Version 1.9.5 |
From: <si...@us...> - 2008-08-03 02:08:59
|
User: sits Date: 08/08/02 19:08:58 Modified: template/en/default listtopics.xml.tmpl . CHANGELOG Log: * Make sure XML representation of a topic has its data properly escaped. Fixed by rob...@us.... Index: listtopics.xml.tmpl =================================================================== RCS file: /cvsroot/codestriker/codestriker/template/en/default/listtopics.xml.tmpl,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- listtopics.xml.tmpl 20 Jun 2008 04:27:15 -0000 1.1 +++ listtopics.xml.tmpl 3 Aug 2008 02:08:58 -0000 1.2 @@ -5,23 +5,23 @@ [% FOREACH topic = alltopics %] <topic> <topicid>[% topic.topicid %]</topicid> - <title>[% topic.title %]</title> - <description>[% topic.description %]</description> - <topic_state>[% topic.topic_state %]</topic_state> + <title>[% topic.title | html_entity %]</title> + <description>[% topic.description | html_entity %]</description> + <topic_state>[% topic.topic_state | html_entity %]</topic_state> <topic_state_id>[% topic.topic_state_id %]</topic_state_id> - <author>[% topic.author %]</author> - <cc>[% topic.cc %]</cc> - <reviewers>[% topic.reviewers %]</reviewers> - <project_name>[% topic.project_name %]</project_name> + <author>[% topic.author | html_entity %]</author> + <cc>[% topic.cc | html_entity %]</cc> + <reviewers>[% topic.reviewers | html_entity %]</reviewers> + <project_name>[% topic.project_name | html_entity %]</project_name> <project_id>[% topic.project_id %]</project_id> [%# Make sure we remove any password from the end of the repository %] - <repository>[% topic.repository.split( ';' ).0 %]</repository> - <module>[% topic.module %]</module> - <start_tag>[% topic.start_tag %]</start_tag> - <end_tag>[% topic.end_tag %]</end_tag> - <bug_ids>[% topic.bug_ids %]</bug_ids> + <repository>[% topic.repository.split( ';' ).0 | html_entity %]</repository> + <module>[% topic.module | html_entity %]</module> + <start_tag>[% topic.start_tag | html_entity %]</start_tag> + <end_tag>[% topic.end_tag | html_entity %]</end_tag> + <bug_ids>[% topic.bug_ids | html_entity %]</bug_ids> <version>[% topic.version %]</version> - <creation_ts>[% topic.creation_ts %]</creation_ts> + <creation_ts>[% topic.creation_ts | html_entity %]</creation_ts> </topic> [% END %] </topics> Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.249 retrieving revision 1.250 diff -u -r1.249 -r1.250 --- CHANGELOG 2 Aug 2008 04:49:07 -0000 1.249 +++ CHANGELOG 3 Aug 2008 02:08:58 -0000 1.250 @@ -16,7 +16,10 @@ * Creation of Subversion topics which use a file for the module field in the create topic screen may not work correctly for some versions of Subversion. This has now been fixed by - rob...@us.... + rob...@us.... + +* Make sure XML representation of a topic has its data properly escaped. + Fixed by rob...@us.... * Ability to parse git patches correctly. |
From: <si...@us...> - 2008-08-04 10:33:38
|
User: sits Date: 08/08/04 03:33:37 Modified: t/FileParser subversion.t git.t . CHANGELOG Added: t/FileParser hg.t test/testtopictexts hg-diff1.txt Log: * Ability to parse hg diffs (Mercurial SCM) correctly. Index: subversion.t =================================================================== RCS file: /cvsroot/codestriker/codestriker/t/FileParser/subversion.t,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- subversion.t 2 Aug 2008 04:47:39 -0000 1.1 +++ subversion.t 4 Aug 2008 10:33:33 -0000 1.2 @@ -3,8 +3,10 @@ use strict; use Fatal qw / open close /; use Test::More tests => 33; +use Test::Differences; use lib '../../lib'; +use Codestriker; use Codestriker::FileParser::SubversionDiff; assert_delta_equals('../../test/testtopictexts/svn-Propdiff1.txt', ()); @@ -12,9 +14,9 @@ assert_delta_equals('../../test/testtopictexts/svn-Propdiff3.txt', ()); assert_delta_equals('../../test/testtopictexts/svn-Propdiff4.txt', make_delta(filename => 'parseBuildLogs', - old_linenumber => 9, - new_linenumber => 9, - revision => 7, + old_linenumber => '9', + new_linenumber => '9', + revision => '7', text => <<'END_DELTA', if [[ "${MYHOSTNAME}" == "compaq" ]]; then DATABASEHOST="elmo"; @@ -29,9 +31,9 @@ END_DELTA ), make_delta(filename => 'buildCleanup.py', - old_linenumber => 28, - new_linenumber => 28, - revision => 7, + old_linenumber => '28', + new_linenumber => '28', + revision => '7', text => <<'END_DELTA', # GCOMDirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/GCOM'] # EPRODirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/EPRODATA'] @@ -49,9 +51,9 @@ assert_delta_equals('../../test/testtopictexts/svn-Propdiff5.txt', make_delta(filename => 'parseBuildLogs', - old_linenumber => 9, - new_linenumber => 9, - revision => 6, + old_linenumber => '9', + new_linenumber => '9', + revision => '6', text => <<'END_DELTA', if [[ "${MYHOSTNAME}" == "compaq" ]]; then DATABASEHOST="elmo"; @@ -66,9 +68,9 @@ END_DELTA ), make_delta(filename => 'buildCleanup.py', - old_linenumber => 28, - new_linenumber => 28, - revision => 6, + old_linenumber => '28', + new_linenumber => '28', + revision => '6', text => <<'END_DELTA', # GCOMDirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/GCOM'] # EPRODirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/EPRODATA'] @@ -86,9 +88,9 @@ assert_delta_equals('../../test/testtopictexts/svn-Propdiff6.txt', make_delta(filename => 'parseBuildLogs', - old_linenumber => 9, - new_linenumber => 9, - revision => 6, + old_linenumber => '9', + new_linenumber => '9', + revision => '6', text => <<'END_DELTA', if [[ "${MYHOSTNAME}" == "compaq" ]]; then DATABASEHOST="elmo"; @@ -103,9 +105,9 @@ END_DELTA ), make_delta(filename => 'buildCleanup.py', - old_linenumber => 28, - new_linenumber => 28, - revision => 6, + old_linenumber => '28', + new_linenumber => '28', + revision => '6', text => <<'END_DELTA', # GCOMDirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/GCOM'] # EPRODirectories = ['/usr/local/apache2/htdocs/docs', '/export/home/buildmaster/cruisecontrol/EPRODATA'] @@ -123,9 +125,9 @@ assert_delta_equals('../../test/testtopictexts/svn-Propdiff7.txt', make_delta(filename => 'users/clechasseur/local/devsetup/CoveoDevSetup.iss', - old_linenumber => 31, - new_linenumber => 31, - revision => 44307, + old_linenumber => '31', + new_linenumber => '31', + revision => '44307', text => <<'END_DELTA', [Languages] @@ -136,9 +138,9 @@ assert_delta_equals('../../test/testtopictexts/svn-Propdiff8.txt', make_delta(filename => 'users/clechasseur/local/devsetup/CoveoDevSetup.iss', - old_linenumber => 31, - new_linenumber => 31, - revision => 44309, + old_linenumber => '31', + new_linenumber => '31', + revision => '44309', text => <<'END_DELTA', [Languages] @@ -149,9 +151,9 @@ assert_delta_equals('../../test/testtopictexts/svn-look-diff1.txt', make_delta(filename => 't1.txt', - old_linenumber => 0, - new_linenumber => 1, - revision => 0, + old_linenumber => '0', + new_linenumber => '1', + revision => '0', text => <<'END_DELTA', +line1 +line2 @@ -161,9 +163,9 @@ assert_delta_equals('../../test/testtopictexts/svn-look-diff2.txt', make_delta(filename => 't1.txt', - old_linenumber => 1, - new_linenumber => 1, - revision => 89, + old_linenumber => '1', + new_linenumber => '1', + revision => '89', text => <<'END_DELTA', +line0 line1 @@ -175,9 +177,9 @@ assert_delta_equals('../../test/testtopictexts/svn-look-diff3.txt', make_delta(filename => 't1.txt', - old_linenumber => 1, - new_linenumber => 0, - revision => 90, + old_linenumber => '1', + new_linenumber => '0', + revision => '90', text => <<'END_DELTA', -line0 -line1 @@ -189,9 +191,9 @@ assert_delta_equals('../../test/testtopictexts/svn-look-diff4.txt', make_delta(filename => 't1.txt', - old_linenumber => 1, - new_linenumber => 1, - revision => 92, + old_linenumber => '1', + new_linenumber => '1', + revision => '92', text => <<'END_DELTA', -l1 +l1 @@ -200,9 +202,9 @@ END_DELTA ), make_delta(filename => 't2.txt', - old_linenumber => 1, - new_linenumber => 0, - revision => 92, + old_linenumber => '1', + new_linenumber => '0', + revision => '92', text => <<'END_DELTA', -l1 END_DELTA @@ -214,11 +216,12 @@ new_linenumber => -1, text => '', binary => 1, + revision => $Codestriker::PATCH_REVISION ), make_delta(filename => 't2.txt', - old_linenumber => 0, - new_linenumber => 1, - revision => 93, + old_linenumber => '0', + new_linenumber => '1', + revision => '93', text => <<'END_DELTA', +aaa +bbb @@ -232,11 +235,12 @@ new_linenumber => -1, text => '', binary => 1, + revision => $Codestriker::REMOVED_REVISION ), make_delta(filename => 't1.txt', - old_linenumber => 1, - new_linenumber => 1, - revision => 94, + old_linenumber => '1', + new_linenumber => '1', + revision => '94', text => <<'END_DELTA', l1 +l11 @@ -246,9 +250,9 @@ END_DELTA ), make_delta(filename => 't2.txt', - old_linenumber => 1, - new_linenumber => 0, - revision => 94, + old_linenumber => '1', + new_linenumber => '0', + revision => '94', text => <<'END_DELTA', -aaa -bbb @@ -256,9 +260,9 @@ END_DELTA ), make_delta(filename => 't3.txt', - old_linenumber => 0, - new_linenumber => 1, - revision => 0, + old_linenumber => '0', + new_linenumber => '1', + revision => '0', text => <<'END_DELTA', +labuda END_DELTA @@ -301,7 +305,7 @@ # Check that the extracted deltas match what is expected. is( @actual, @expected, "Number of deltas for file: $filename" ); for ( my $index = 0; $index < @actual; $index++ ) { - is_deeply( $actual[$index], $expected[$index], - "Delta $index in file $filename" ); + eq_or_diff( $actual[$index], $expected[$index], + "Delta $index in file $filename" ); } } \ No newline at end of file Index: git.t =================================================================== RCS file: /cvsroot/codestriker/codestriker/t/FileParser/git.t,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- git.t 14 Jul 2008 06:54:00 -0000 1.2 +++ git.t 4 Aug 2008 10:33:33 -0000 1.3 @@ -5,6 +5,7 @@ use Test::More tests => 7; use lib '../../lib'; +use Codestriker; use Codestriker::FileParser::PatchUnidiff; # Parse the test git patch file. Index: hg.t =================================================================== RCS file: hg.t diff -N hg.t --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ hg.t 4 Aug 2008 10:33:33 -0000 1.1 @@ -0,0 +1,126 @@ +# Tests to ensure that hg diffs (Mercurial SCM) are handled correctly. + +use strict; +use Fatal qw / open close /; +use Test::More tests => 6; + +use lib '../../lib'; +use Codestriker; +use Codestriker::FileParser::PatchUnidiff; + +# Parse the test hg patch file. +my $fh; +open( $fh, '<', '../../test/testtopictexts/hg-diff1.txt' ); +my @deltas = Codestriker::FileParser::PatchUnidiff->parse($fh); +close($fh); + +# Set what the expected output should be. +my @expected; +push @expected, make_delta( + filename => 'b/addedtest.txt', + old_linenumber => 0, + new_linenumber => 1, + revision => $Codestriker::ADDED_REVISION, + text => <<'END_DELTA', ++Lorem ipsum dolor sit amet, consectetuer ++adipiscing elit. Sed laoreet erat vel arcu. Vestibulum ++ante ipsum primis in faucibus orci luctus et ultrices posuere ++cubilia Curae; Aliquam et diam ac nisi congue semper. Nulla ++consequat. Cras molestie dictum turpis. Aenean lorem diam, ++luctus at, tempus ac, semper ut, lorem. Nulla consequat, velit ++eu tincidunt commodo, diam lorem sodales leo, vitae aliquet leo ++leo eget eros. Vestibulum consectetuer iaculis pede. ++Suspendisse potenti. Sed non magna. Donec vel augue. ++Sed iaculis nisi sed nunc. Sed cursus tellus eu risus. ++Ut eros quam, imperdiet et, ultricies non, iaculis at, sem. ++Donec et lacus in massa aliquet pretium. Suspendisse lacus. ++Vestibulum ante ipsum primis in faucib ++us orci luctus et ultrices posuere cubilia Curae; +END_DELTA +); + +push @expected, make_delta( + filename => 'a/deletetest.txt', + old_linenumber => 1, + new_linenumber => 0, + revision => $Codestriker::REMOVED_REVISION, + text => <<'END_DELTA', +-Class aptent taciti sociosqu ad litora torquent +-per conubia nostra, per inceptos himenaeos. +-Aliquam auctor. Proin tempor commodo nisl. +END_DELTA +); + +push @expected, make_delta( + filename => 'b/feedback.html', + old_linenumber => 10, + new_linenumber => 10, + text => <<'END_DELTA', + } + div.modalFeedback h1{ + margin: 20px 20px 20px 20px; +- font-size: 18pt; + } + #feedbackForm textarea { + font-family: Arial,Helvetica,sans-serif; +END_DELTA +); + +push @expected, make_delta( + filename => 'b/feedback.html', + old_linenumber => 23, + new_linenumber => 22, + text => <<'END_DELTA', + border: solid 3px #ddddFF; + padding: 3px; + width: 50px; ++ height: 50px; + } + #feedbackForm input#feedback_email{ + width: 60%; +END_DELTA +); + +push @expected, make_delta( + filename => 'b/feedback.html', + old_linenumber => 31, + new_linenumber => 31, + text => <<'END_DELTA', + </head> + <body> + +-Hello from hg ++Hello to codestriker from hg + + </body> + </html> +END_DELTA +); + +# Check that the extracted deltas match what is expected. +is( @deltas, @expected, "Number of deltas in hg diff 1" ); +for ( my $index = 0; $index < @deltas; $index++ ) { + is_deeply( $deltas[$index], $expected[$index], + "Delta $index in hg diff 1" ); +} + +# Convenience function for creating a delta object. +sub make_delta { + + # Set constant properties for all git deltas. + my $delta = {}; + $delta->{binary} = 0; + $delta->{repmatch} = 0; + $delta->{revision} = $Codestriker::PATCH_REVISION; + $delta->{description} = ''; + + # Apply the passed in arguments. + my %arg = @_; + $delta->{filename} = $arg{filename}; + $delta->{old_linenumber} = $arg{old_linenumber}; + $delta->{new_linenumber} = $arg{new_linenumber}; + $delta->{text} = $arg{text}; + $delta->{revision} = $arg{revision} if exists $arg{revision}; + + return $delta; +} Index: hg-diff1.txt =================================================================== RCS file: hg-diff1.txt diff -N hg-diff1.txt --- /dev/null 1 Jan 1970 00:00:00 -0000 +++ hg-diff1.txt 4 Aug 2008 10:33:34 -0000 1.1 @@ -0,0 +1,54 @@ +diff -r 24ed0f64c715 -r 6d633e6509fe addedtest.txt +--- /dev/null Thu Jan 01 00:00:00 1970 +0000 ++++ b/addedtest.txt Sun Aug 03 16:58:46 2008 +0200 +@@ -0,0 +1,14 @@ ++Lorem ipsum dolor sit amet, consectetuer ++adipiscing elit. Sed laoreet erat vel arcu. Vestibulum ++ante ipsum primis in faucibus orci luctus et ultrices posuere ++cubilia Curae; Aliquam et diam ac nisi congue semper. Nulla ++consequat. Cras molestie dictum turpis. Aenean lorem diam, ++luctus at, tempus ac, semper ut, lorem. Nulla consequat, velit ++eu tincidunt commodo, diam lorem sodales leo, vitae aliquet leo ++leo eget eros. Vestibulum consectetuer iaculis pede. ++Suspendisse potenti. Sed non magna. Donec vel augue. ++Sed iaculis nisi sed nunc. Sed cursus tellus eu risus. ++Ut eros quam, imperdiet et, ultricies non, iaculis at, sem. ++Donec et lacus in massa aliquet pretium. Suspendisse lacus. ++Vestibulum ante ipsum primis in faucib ++us orci luctus et ultrices posuere cubilia Curae; +\ No newline at end of file +diff -r 24ed0f64c715 -r 6d633e6509fe deletetest.txt +--- a/deletetest.txt Sun Aug 03 16:57:40 2008 +0200 ++++ /dev/null Thu Jan 01 00:00:00 1970 +0000 +@@ -1,3 +0,0 @@ +-Class aptent taciti sociosqu ad litora torquent +-per conubia nostra, per inceptos himenaeos. +-Aliquam auctor. Proin tempor commodo nisl. +diff -r 24ed0f64c715 -r 6d633e6509fe feedback.html +--- a/feedback.html Sun Aug 03 16:57:40 2008 +0200 ++++ b/feedback.html Sun Aug 03 16:58:46 2008 +0200 +@@ -10,7 +10,6 @@ + } + div.modalFeedback h1{ + margin: 20px 20px 20px 20px; +- font-size: 18pt; + } + #feedbackForm textarea { + font-family: Arial,Helvetica,sans-serif; +@@ -23,6 +22,7 @@ + border: solid 3px #ddddFF; + padding: 3px; + width: 50px; ++ height: 50px; + } + #feedbackForm input#feedback_email{ + width: 60%; +@@ -31,7 +31,7 @@ + </head> + <body> + +-Hello from hg ++Hello to codestriker from hg + + </body> + </html> Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.250 retrieving revision 1.251 diff -u -r1.250 -r1.251 --- CHANGELOG 3 Aug 2008 02:08:58 -0000 1.250 +++ CHANGELOG 4 Aug 2008 10:33:34 -0000 1.251 @@ -23,6 +23,8 @@ * Ability to parse git patches correctly. +* Ability to parse hg diffs (Mercurial SCM) correctly. + * Better detection of filename extensions for highlighting. This previously caused issues for temporary directories which contained a period, but the filename itself didn't. Reported by |
From: <si...@us...> - 2008-08-05 10:45:14
|
User: sits Date: 08/08/05 03:45:13 Modified: . CHANGELOG Log: Updated to reflect last commit. Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.252 retrieving revision 1.253 diff -u -r1.252 -r1.253 --- CHANGELOG 4 Aug 2008 11:22:55 -0000 1.252 +++ CHANGELOG 5 Aug 2008 10:45:12 -0000 1.253 @@ -39,7 +39,11 @@ Reported by cle...@us.... * Show total added/removed line count after table of contents on view - topic screen. Also show same line counts on create topic email. + topic screen. Also show same line counts on create topic email. + +* Make the topic title in the edit comment page link directly to the + code location being commented on rather than just the top of the + view topic page. Version 1.9.5 |
From: <si...@us...> - 2008-08-11 03:58:12
|
User: sits Date: 08/08/10 20:58:11 Modified: lib Codestriker.pm doc codestriker.sgml . CHANGELOG Log: * Created another Subversion post-commit script which is an extension of the standard commit-email.pl script which ships with Subversion. The email sent also includes an additional line, which is the URL to the auto-created topic. Index: Codestriker.pm =================================================================== RCS file: /cvsroot/codestriker/codestriker/lib/Codestriker.pm,v retrieving revision 1.109 retrieving revision 1.110 diff -u -r1.109 -r1.110 --- Codestriker.pm 8 Aug 2008 06:53:07 -0000 1.109 +++ Codestriker.pm 11 Aug 2008 03:58:11 -0000 1.110 @@ -36,7 +36,7 @@ ); # Version of Codestriker. -$Codestriker::VERSION = "1.9.6"; +$Codestriker::VERSION = "1.9.7"; # Default title to display on each Codestriker screen. $Codestriker::title = "Codestriker $Codestriker::VERSION"; Index: codestriker.sgml =================================================================== RCS file: /cvsroot/codestriker/codestriker/doc/codestriker.sgml,v retrieving revision 1.69 retrieving revision 1.70 diff -u -r1.69 -r1.70 --- codestriker.sgml 8 Aug 2008 06:10:13 -0000 1.69 +++ codestriker.sgml 11 Aug 2008 03:58:11 -0000 1.70 @@ -1886,7 +1886,8 @@ </para> <para> It is possible to create Codestriker topics automatically after - each Subversion commit, via the bin/subversion-post-commit.pl script. + each Subversion commit, via the + <filename>bin/subversion-post-commit.pl</filename> script. Once the appropriate configuration is set at the start of the file, simply add it to your Subversion <filename>repos/hooks/post-commit</filename> the path to the file as follows: @@ -1894,6 +1895,25 @@ /path/to/codestriker/bin/subversion-post-commit.pl "$REPOS" "$REV" </programlisting> </para> + <para> + Another option is to use the standard <filename>commit-email.pl</filename> + script that ships with Subversion which sends out email diffs from + each commit. It has been updated to also allow the possibility of + creating a Codestriker topic automatically as well. This updated + script is available in <filename>bin/commit-email-codestriker.pl</filename>. + The email sent out will contain an additional + line, which is the URL to the Codestriker topic. All Codestriker + configuration is passed via the command line, as this example shows: +<programlisting> + /path/to/codestriker/bin/commit-email-codestriker.pl -h company.com + --codestriker-url http://company.com/codestriker/codestriker.pl + --codestriker-project "Subversion Commits" + --codestriker-repository "svn://hostname/var/svn/repos/fbi2/trunk" + --codestriker-reviewers "eng...@co..." + --codestriker-install-dir /var/www/codestriker + "$REPOS" "$REV" eng...@co... +</programlisting> + </para> </sect2> <sect2> <title>Creating Perforce Diff Topics</title> Index: CHANGELOG =================================================================== RCS file: /cvsroot/codestriker/codestriker/CHANGELOG,v retrieving revision 1.257 retrieving revision 1.258 diff -u -r1.257 -r1.258 --- CHANGELOG 8 Aug 2008 05:41:10 -0000 1.257 +++ CHANGELOG 11 Aug 2008 03:58:11 -0000 1.258 @@ -1,6 +1,13 @@ *** When upgrading, don't forget to: "cd bin ; ./install.pl" *** *** Also, it is _highly_ advisable to backup your data before upgrading *** +Version 1.9.7 + +* Created another Subversion post-commit script which is an extension + of the standard commit-email.pl script which ships with Subversion. + The email sent also includes an additional line, which is the URL to + the auto-created topic. + Version 1.9.6 * Ability to create Codestriker topics automatically from a Subversion |