ftp5.freebsd.org does not support tar on the fly
use short arguments for url.cgi
This commit is contained in:
parent
3d222a2113
commit
45f9a6661d
Notes:
svn2git
2020-12-08 03:00:23 +00:00
svn path=/www/; revision=9398
1 changed files with 7 additions and 5 deletions
|
@ -20,13 +20,15 @@ if ($ENV{'MASTER_FTP_SERVER'}) {
|
|||
} else {
|
||||
$ftpserver = 'ftp://ftp5.freebsd.org' if !$ftpserver;
|
||||
}
|
||||
$base = "$ftpserver/pub/FreeBSD/branches/-current" if !$base;
|
||||
$base = "" if !$base;
|
||||
$baseHTTP = $base if !$baseHTTP;
|
||||
$baseFTP = "$ftpserver/pub/FreeBSD/branches/-current/";
|
||||
$urlcgi = 'http://www.freebsd.org/cgi/url.cgi' if !$urlcgi;
|
||||
$packagesURL = "$ftpserver/pub/FreeBSD/ports/i386/packages-stable/All/"
|
||||
if !$packagesURL;
|
||||
# support tar on the fly or gzip'ed tar on the fly
|
||||
$ftparchive = 'tar' if !$ftparchive;
|
||||
$ftparchive = '';
|
||||
$ftparchive = 'tar' if !defined $ftparchive;
|
||||
|
||||
|
||||
# ports download sources script
|
||||
|
@ -141,11 +143,11 @@ sub main {
|
|||
$stats{$i}++;
|
||||
|
||||
# figure out the FTP url
|
||||
$loc =~ s/\/usr/$base/;
|
||||
$ldesc =~ s/\/usr/$baseHTTP/;
|
||||
$loc =~ s/\/usr\//$baseFTP/;
|
||||
$ldesc =~ s/\/usr\//$baseHTTP/;
|
||||
|
||||
# The name description and maintainer
|
||||
$data{$i} .= "<DT><B><A NAME=\"$name\"></A><A HREF=\"$loc.$ftparchive\">$name</A></B> ";
|
||||
$data{$i} .= "<DT><B><A NAME=\"$name\"></A><A HREF=\"$loc$ftparchive\">$name</A></B> ";
|
||||
|
||||
|
||||
$data{$i} .= "<DD>$desc<BR><A HREF=\"$ldesc\">Long description</A>";
|
||||
|
|
Loading…
Reference in a new issue