- if ($remote_mtime eq 0)
- {
- $metadata[2] = $sfUnknown;
- if ($debug) { &writelog("$updatefile - WARNING: Source not found"); }
- print "$updatefile - WARNING: Source not found\n";
- }
- elsif (($local_mtime eq $remote_mtime) && ($local_size == $remote_size))
- {
- $metadata[2] = $sfOk;
- $metadata[3] = time;
- if ($debug) { &writelog("$updatefile"); }
- print "$updatefile\n";
- }
- else
- {
- $metadata[2] = $sfOutdated;
- $metadata[3] = time;
- if ($debug) { &writelog("$updatefile - WARNING: Out of date"); }
- print "$updatefile - WARNING: Out of date\n";
- if ($download)
- {
- if ($debug)
- {
- 1 while $remote_size =~ s/^(-?\d+)(\d{3})/$1.$2/;
- print "Please wait, retrieving file ($remote_size Byte) from source ...";
- `$scriptpath/../bin/wget -nd -nv -O $repository/$updatefile $sourceurl >>$logfile 2>&1`;
- print "\n";
- } else
- {
- `$scriptpath/../bin/wget -nd -nv -O $repository/$updatefile $sourceurl 2>&1`;
- }
- $local_mtime = &getmtime("$repository/$updatefile");
- if ($local_mtime eq $remote_mtime) { $metadata[2] = $sfOk; }
- }
- }
- open (FILE,">$repository/metadata/$updatefile");
- foreach (@metadata) { print FILE "$_\n"; }
+foreach (@sources)
+{
+ @updatelist=<$_/*>;
+ foreach(@updatelist)
+ {
+ if (-e "$_/source.url")
+ {
+ open (FILE,"$_/source.url");
+ $sourceurl=<FILE>;