You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@subversion.apache.org by ja...@apache.org on 2016/02/08 01:39:43 UTC
svn commit: r1729060 - /subversion/trunk/tools/client-side/svn-graph.pl
Author: jamessan
Date: Mon Feb 8 00:39:43 2016
New Revision: 1729060
URL: http://svn.apache.org/viewvc?rev=1729060&view=rev
Log:
* tools/client-side/svn-graph.pl
(): Use direct method invocation to construct SVN::Client
(parse_commandline): Canonicalize the given repo URI
(write_graph_descriptor): Use the canonical form of the relpath for the root
of the repo.
Modified:
subversion/trunk/tools/client-side/svn-graph.pl
Modified: subversion/trunk/tools/client-side/svn-graph.pl
URL: http://svn.apache.org/viewvc/subversion/trunk/tools/client-side/svn-graph.pl?rev=1729060&r1=1729059&r2=1729060&view=diff
==============================================================================
--- subversion/trunk/tools/client-side/svn-graph.pl (original)
+++ subversion/trunk/tools/client-side/svn-graph.pl Mon Feb 8 00:39:43 2016
@@ -62,7 +62,7 @@ parse_commandline();
# Point at the root of a repository so we get can look at
# every revision.
-my $auth = (new SVN::Client())->auth;
+my $auth = SVN::Client->new->auth;
my $ra = SVN::Ra->new(url => $repos_url, auth => $auth);
# Handle identifier for the aboslutely youngest revision.
@@ -110,7 +110,7 @@ usage: svn-graph.pl [-r START_REV:END_RE
getopts('r:p:h', \%cmd_opts) or die $usage;
die $usage if scalar(@ARGV) < 1;
- $repos_url = $ARGV[0];
+ $repos_url = SVN::Core::uri_canonicalize($ARGV[0]);
$cmd_opts{'r'} =~ m/(\d+)(:(.+))?/;
if ($3)
@@ -215,7 +215,7 @@ sub write_graph_descriptor
print "\n";
# Retrieve the requested history.
- $ra->get_log(['/'], $startrev, $youngest, 0, 1, 0, \&process_revision);
+ $ra->get_log([''], $startrev, $youngest, 0, 1, 0, \&process_revision);
# Now ensure that everything is linked.
foreach my $codeline_change (keys %codeline_changes_forward)
RE: svn commit: r1729060 - /subversion/trunk/tools/client-side/svn-graph.pl
Posted by Bert Huijben <be...@qqmail.nl>.
> -----Original Message-----
> From: jamessan@apache.org [mailto:jamessan@apache.org]
> Sent: maandag 8 februari 2016 01:40
> To: commits@subversion.apache.org
> Subject: svn commit: r1729060 - /subversion/trunk/tools/client-side/svn-
> graph.pl
>
> Author: jamessan
> Date: Mon Feb 8 00:39:43 2016
> New Revision: 1729060
>
> URL: http://svn.apache.org/viewvc?rev=1729060&view=rev
> Log:
> * tools/client-side/svn-graph.pl
> (): Use direct method invocation to construct SVN::Client
> (parse_commandline): Canonicalize the given repo URI
> (write_graph_descriptor): Use the canonical form of the relpath for the root
> of the repo.
>
> Modified:
> subversion/trunk/tools/client-side/svn-graph.pl
>
> Modified: subversion/trunk/tools/client-side/svn-graph.pl
> URL: http://svn.apache.org/viewvc/subversion/trunk/tools/client-side/svn-
> graph.pl?rev=1729060&r1=1729059&r2=1729060&view=diff
> ==========================================================
> ====================
> --- subversion/trunk/tools/client-side/svn-graph.pl (original)
> +++ subversion/trunk/tools/client-side/svn-graph.pl Mon Feb 8 00:39:43
> 2016
> @@ -62,7 +62,7 @@ parse_commandline();
>
> # Point at the root of a repository so we get can look at
> # every revision.
> -my $auth = (new SVN::Client())->auth;
> +my $auth = SVN::Client->new->auth;
Technically this auth instance has the same lifetime as this SVN::Client. I don't know how this is exposed in the perl code (and if that lifetime matches that of the application), but it would be cleaner to also keep the client instance in a different variable.
> my $ra = SVN::Ra->new(url => $repos_url, auth => $auth);
And there are helper functions on the client to create an Ra session from that, which automatically hook a few other features that are now ignored.
Bert
RE: svn commit: r1729060 - /subversion/trunk/tools/client-side/svn-graph.pl
Posted by Bert Huijben <be...@qqmail.nl>.
> -----Original Message-----
> From: jamessan@apache.org [mailto:jamessan@apache.org]
> Sent: maandag 8 februari 2016 01:40
> To: commits@subversion.apache.org
> Subject: svn commit: r1729060 - /subversion/trunk/tools/client-side/svn-
> graph.pl
>
> Author: jamessan
> Date: Mon Feb 8 00:39:43 2016
> New Revision: 1729060
>
> URL: http://svn.apache.org/viewvc?rev=1729060&view=rev
> Log:
> * tools/client-side/svn-graph.pl
> (): Use direct method invocation to construct SVN::Client
> (parse_commandline): Canonicalize the given repo URI
> (write_graph_descriptor): Use the canonical form of the relpath for the root
> of the repo.
>
> Modified:
> subversion/trunk/tools/client-side/svn-graph.pl
>
> Modified: subversion/trunk/tools/client-side/svn-graph.pl
> URL: http://svn.apache.org/viewvc/subversion/trunk/tools/client-side/svn-
> graph.pl?rev=1729060&r1=1729059&r2=1729060&view=diff
> ==========================================================
> ====================
> --- subversion/trunk/tools/client-side/svn-graph.pl (original)
> +++ subversion/trunk/tools/client-side/svn-graph.pl Mon Feb 8 00:39:43
> 2016
> @@ -62,7 +62,7 @@ parse_commandline();
>
> # Point at the root of a repository so we get can look at
> # every revision.
> -my $auth = (new SVN::Client())->auth;
> +my $auth = SVN::Client->new->auth;
Technically this auth instance has the same lifetime as this SVN::Client. I don't know how this is exposed in the perl code (and if that lifetime matches that of the application), but it would be cleaner to also keep the client instance in a different variable.
> my $ra = SVN::Ra->new(url => $repos_url, auth => $auth);
And there are helper functions on the client to create an Ra session from that, which automatically hook a few other features that are now ignored.
Bert