Bug 344035 - path is doubled when resolving conflicts
Summary: path is doubled when resolving conflicts
Status: RESOLVED DUPLICATE of bug 322182
Alias: None
Product: kdesvn
Classification: Applications
Component: General (show other bugs)
Version: 1.6.0
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: KDESvn default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-02-11 13:52 UTC by Oliver Konz
Modified: 2015-12-13 16:46 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Oliver Konz 2015-02-11 13:52:07 UTC
When I try to resolve a conflict all paths are printed twice on the kdiff3 command line. I use the default settings: kdiff3 %o %m %n -o %t

e.g. I want to resolve a conflict in /path/to/file.java the command line generated for kdiff3 looks like this:

kdiff3 /path/to/path/to/file.java.r123 /path/to/path/to/file.java.mine /path/to/path/to/file.java.r134 -o /path/to/path/to/file.java


Reproducible: Always

Steps to Reproduce:
Try to resolve a conflict.

Actual Results:  
kdiff3 /path/to/path/to/file.java.r123 /path/to/path/to/file.java.mine /path/to/path/to/file.java.r134 -o /path/to/path/to/file.java

Expected Results:  
kdiff3 /path/to/file.java.r123 /path/to/file.java.mine /path/to/file.java.r134 -o /path/to/file.java
Comment 1 stephan.mucha 2015-06-09 11:45:30 UTC
I wrote the following perl script as quick and dirty workaround. sure, one could correct the bug in the application itself, buuut: I'm not familiar with C++/Qt/KDE  and it would take ages.

just copy in an editor, save as kdiff3_pathstrip or something somewhere in your PATH. don't forget to make it executable. then in kdesvn change preferences to launch kdiff3_pathstrip (same arguments), so my settings for external merging/conflict editing are: 
kdiff3_pathstrip %s1 %s2 %t
kdiff3_pathstrip %o %m %n -o %t

BEWARE: 
no warranties. :-) it is really dirty (to keep pattern matching simple, it works only for files under /home/....   if your file are elsewhere you have to tweak it accordingly.

#++++++++++++++++++++++++ snap ++++++++++++++++++++++
#!/usr/bin/perl

my (@args)=(@ARGV);

for my $arg (@args) {
  if (defined $arg) {
     $arg =~ s|/home.*/home|/home|;
  }
}
my ($o,$m,$n,$p,$t) = @args;

my $cmd = "kdiff3 $o $m $n";
if (defined $t) {
$cmd .= " -o $t ";
}

system($cmd);
#++++++++++++++++++++++++ snap ++++++++++++++++++++++
Comment 2 Christian Ehrlicher 2015-12-13 16:46:10 UTC

*** This bug has been marked as a duplicate of bug 322182 ***