From 98a68a9249b3ea51b1f148cbcbbf061151273506 Mon Sep 17 00:00:00 2001 From: Don Armstrong Date: Sat, 27 Oct 2007 01:24:56 +0000 Subject: [PATCH] * Fixup urls better in get_sgf --- get_sgf | 2 ++ 1 file changed, 2 insertions(+) diff --git a/get_sgf b/get_sgf index 090ba8d..229424c 100755 --- a/get_sgf +++ b/get_sgf @@ -113,6 +113,8 @@ my $base = 'http://gobase.org/online/sgf2misc/?fname=/games/japan/titles/kisei/3 for my $url (@ARGV) { # strip of leading stuff $url =~ s/[^=]+=//; + $url =~ s{(?:http://)?(?:gobase\.org)?}{}; + $url = qq(/$url) unless $url =~ m{^/}; my $fname = $url; my $uri = URI->new($base); $uri->query_form(mode => $options{mode}, -- 2.39.2