Perforce 'describe' style diff broken... and fixed!

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Perforce 'describe' style diff broken... and fixed!

Preston Jennings
Hello all,

I encountered an issue when using the Perforce 'describe' style diff
(this is where you supply the changelist number and the diff is
fetched using the p4 command line tool's 'describe' function). Anyways
the fix was easy enough (though it did take a few hours to hunt around
and learn perl) - one of the arguments in the command line was missing
a hyphen:

lib/Codestriker/Repository/Perforce.pm  (line 116 as of version 1.9.10):

 else { # original case with just one tag specified.
       my $tag = $start_tag ne '' ? $start_tag : $end_tag;

       push @args, 'describe';
       push @args, 'du';   ###########  <---  this needs to be '-du'
       push @args, $tag;
   }

The result was that creating a topic would end up having incorrect
diffs as the default perforce diff format is different from the
unified diff spec.

Can someone please submit this fix on my behalf?

Thanks, Preston

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Codestriker-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/codestriker-user
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Perforce 'describe' style diff broken... and fixed!

David Sitsky
Administrator
Hi Preston,

Thanks for submitting that.

Cheers,
David

On Wed, Jan 18, 2012 at 10:26 AM, Preston Jennings <[hidden email]> wrote:

> Hello all,
>
> I encountered an issue when using the Perforce 'describe' style diff
> (this is where you supply the changelist number and the diff is
> fetched using the p4 command line tool's 'describe' function). Anyways
> the fix was easy enough (though it did take a few hours to hunt around
> and learn perl) - one of the arguments in the command line was missing
> a hyphen:
>
> lib/Codestriker/Repository/Perforce.pm  (line 116 as of version 1.9.10):
>
>  else { # original case with just one tag specified.
>        my $tag = $start_tag ne '' ? $start_tag : $end_tag;
>
>        push @args, 'describe';
>        push @args, 'du';   ###########  <---  this needs to be '-du'
>        push @args, $tag;
>    }
>
> The result was that creating a topic would end up having incorrect
> diffs as the default perforce diff format is different from the
> unified diff spec.
>
> Can someone please submit this fix on my behalf?
>
> Thanks, Preston
>
> ------------------------------------------------------------------------------
> Keep Your Developer Skills Current with LearnDevNow!
> The most comprehensive online learning library for Microsoft developers
> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
> Metro Style Apps, more. Free future releases when you subscribe now!
> http://p.sf.net/sfu/learndevnow-d2d
> _______________________________________________
> Codestriker-user mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/codestriker-user

------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Codestriker-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/codestriker-user
Loading...