diff options
author | Ian Jackson <ijackson@chiark.greenend.org.uk> | 2013-08-16 16:35:03 +0100 |
---|---|---|
committer | Ian Jackson <ijackson@chiark.greenend.org.uk> | 2013-08-16 16:35:03 +0100 |
commit | 12dc1b71aa58bd4d044077b4f921580cedb0c347 (patch) | |
tree | dc34ac1daec6f96a800855e07f307c219d196bd7 | |
parent | 713eaae4d3f172cca513f90c2a0a00501f440bd6 (diff) |
configurable mirror
-rwxr-xr-x | dgit | 7 | ||||
-rw-r--r-- | dgit.1 | 2 |
2 files changed, 6 insertions, 3 deletions
@@ -26,7 +26,6 @@ use Dpkg::Control::Hash; use File::Path; use POSIX; -our $mirror = 'http://mirror.relativity.greenend.org.uk/mirror/debian-ftp/'; our $suite = 'sid'; our $package; @@ -139,7 +138,8 @@ our %defcfg = ('dgit.default.distro' => 'debian', 'dgit-distro.debian.git-proto' => 'git+ssh://', 'dgit-distro.debian.git-path' => '/git/dgit-repos', 'dgit-distro.debian.git-check' => 'ssh-cmd', - 'dgit-distro.debian.git-create' => 'ssh-cmd'); + 'dgit-distro.debian.git-create' => 'ssh-cmd', + 'dgit-distro.debian.mirror' => 'http://ftp.debian.org/debian/'); sub cfg { foreach my $c (@_) { @@ -224,7 +224,8 @@ sub get_archive_dsc () { my $vsn = askmadison(); # fixme madison does not show us the component my $prefix = substr($package, 0, $package =~ m/^l/ ? 4 : 1); - $dscurl = "$mirror/pool/main/$prefix/$package/${package}_$vsn.dsc"; + $dscurl = access_cfg('mirror'). + "/pool/main/$prefix/$package/${package}_$vsn.dsc"; $dscdata = url_get($dscurl); my $dscfh = new IO::File \$dscdata, '<' or die $!; print DEBUG Dumper($dscdata); @@ -160,6 +160,8 @@ on the dgit command line. .TP .BI dgit-distro. distro .upload-host .TP +.BI dgit-distro. distro .mirror +.TP .BI dgit-distro. distro .ssh .TP .BR dgit.default. * |