2 new commits in mtrack:
https://bitbucket.org/wez/mtrack/changeset/df5b6b3e14f7/
changeset: df5b6b3e14f7
user: wez
date: 2012-04-30 02:06:45
summary: resolves an issue with rendering diffs containing latin1 and not utf-8
data.
affected #: 1 file
diff -r 4b22c77f1c44213c42da6cab9a96a49815106bf2 -r df5b6b3e14f70c3788d0f4fa1756f09732ea024f inc/web.php
--- a/inc/web.php
+++ b/inc/web.php
@@ -1099,7 +1099,9 @@
$anchor = $abase . '.' . $nlines;
$row .= "<td class='linelink'><a name='$anchor'></a><a href='#$anchor' title='link to this line'>#</a></td>";
- $line = htmlspecialchars($line, ENT_QUOTES, 'utf-8');
+ // deliberately don't inform it of the charset; we have no idea and we
+ // only really care about the obvious HTML metacharacters, not the entities
+ $line = htmlspecialchars($line);
$row .= "<td class='line' width='100%'>$line</td></tr>\n";
$html .= $row;
https://bitbucket.org/wez/mtrack/changeset/21b1e8711cda/
changeset: 21b1e8711cda
user: wez
date: 2012-04-30 02:08:35
summary: fix some timeline issues:
* svn changesets could show up with strange empty changeset numbers
* commits that don't use refs ticket commands could show up in the
timeline with doubled-up commit messages.
affected #: 2 files
diff -r df5b6b3e14f70c3788d0f4fa1756f09732ea024f -r 21b1e8711cda66a94838268861fbc0a0df65b731 bin/svn-commit-hook
--- a/bin/svn-commit-hook
+++ b/bin/svn-commit-hook
@@ -24,7 +24,9 @@
}
-class SvnCommitHookBridge implements IMTrackCommitHookBridge {
+class SvnCommitHookBridge implements IMTrackCommitHookBridge,
+ IMTrackCommitHookBridge2
+{
var $repo;
var $svnlook;
var $svnrepo;
@@ -69,6 +71,17 @@
$rev = trim(str_replace('-r ', '', $this->svntxn));
return '[changeset:' . $this->repo->getBrowseRootName() . ",$rev]";
}
+
+ function getChanges() {
+ $c = new MTrackCommitHookChangeEvent;
+ $rev = trim(str_replace('-r ', '', $this->svntxn));
+ $c->hash = $rev;
+ $c->rev = $this->getChangesetDescriptor();
+ $c->changelog = $this->getCommitMessage();
+ $c->changeby = MTrackAuth::whoami();
+ $c->ctime = time();
+ return array($c);
+ }
}
try {
diff -r df5b6b3e14f70c3788d0f4fa1756f09732ea024f -r 21b1e8711cda66a94838268861fbc0a0df65b731 inc/timeline.php
--- a/inc/timeline.php
+++ b/inc/timeline.php
@@ -338,12 +338,21 @@
/* doesn't ref a ticket; ensure that we see which
* changeset it came from if it doesn't already
* mention it */
+
+ if ($ent->rev === null) {
+ // Ugh, workaround a bug that recorded the rev
+ // as null in the audit.
+ continue;
+ }
+
$cslink =
"[changeset:" . $R->getBrowseRootName() . ',' .
$ent->rev . ']';
if (strpos($row['reason'], $cslink) === false) {
- $add = ' ' . $cslink . ' ' . $ent->changelog;
- $row['reason'] .= $add;
+ $row['reason'] .= " (In $cslink)";
+ }
+ if (strpos($row['reason'], trim($ent->changelog)) === false) {
+ $row['reason'] .= ' ' . $ent->changelog;
}
}
}
Repository URL:
https://bitbucket.org/wez/mtrack/
--
This is a commit notification from
bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.