Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit aefcfed

Browse files
vincentselsdregad
authored andcommittedDec 7, 2012
Support viewing files and diff from deleted branch
When trying to see files or view diff between files from a branch that has been marked as deleted (like a reintegrated feature branch), websvn displayed an error saying that file does not exist at that specific revision, even though it actually does. Adding peg=<rev> fixes this. Reference: ticket http://leetcode.net/mantis/view.php?id=237 Fixes #6 Signed-off-by: Damien Regad <damien.regad@merckgroup.com>
1 parent 1a9d349 commit aefcfed

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed
 

‎SourceWebSVN/SourceWebSVN.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,15 +52,17 @@ public function url_file( $p_repo, $p_changeset, $p_file ) {
5252
return '';
5353
}
5454
return $p_repo->info['websvn_url'] . 'filedetails.php?repname=' . urlencode( $p_repo->info['websvn_name'] ) .
55-
'&rev=' . urlencode( $p_changeset->revision ) . '&path=' . urlencode( $p_file->filename ) . '&sc=1';
55+
'&rev=' . urlencode( $p_changeset->revision ) . '&peg=' . urlencode( $p_changeset->revision ) .
56+
'&path=' . urlencode( $p_file->filename ) . '&sc=1';
5657
}
5758

5859
public function url_diff( $p_repo, $p_changeset, $p_file ) {
5960
if ( $p_file->action == 'D' || $p_file->action == 'A' ) {
6061
return '';
6162
}
6263
return $p_repo->info['websvn_url'] . 'diff.php?repname=' . urlencode( $p_repo->info['websvn_name'] ) .
63-
'&rev=' . urlencode( $p_changeset->revision ) . '&path=' . urlencode( $p_file->filename ) . '&sc=1';
64+
'&rev=' . urlencode( $p_changeset->revision ) . '&peg=' . urlencode( $p_changeset->revision ) .
65+
'&path=' . urlencode( $p_file->filename ) . '&sc=1';
6466
}
6567

6668
public function update_repo_form( $p_repo ) {

0 commit comments

Comments
 (0)
Please sign in to comment.