Temporarily disabled “restore” option because it needs more work to actually work
This commit is contained in:
parent
61d0fcb3d8
commit
edee66b834
1 changed files with 7 additions and 1 deletions
|
@ -74,6 +74,7 @@ OPTIONS
|
|||
doing anything. With this option the lockfile is ignored. Please verify
|
||||
that the program is not already running before using it.
|
||||
-r, --restore
|
||||
>>> Currently not working, causes script to just exit with an error message.
|
||||
If peers files «peers», «peers.all», «peers.checked» exist on program’s
|
||||
start they will be loaded, thus allowing to restore an interrupted previous
|
||||
crawling session. This option is mutually exclusive with the «loop» option.
|
||||
|
@ -156,6 +157,8 @@ for ($i=1; $i<$argc; $i++) {
|
|||
}
|
||||
}
|
||||
|
||||
if ($opts['restore']) mexit('Error: “restore” option’s code has to be finished, it currently doesn’t work; exiting.'.N,1);
|
||||
|
||||
if ($opts['loop'] && $opts['restore']) mexit('Error: “loop” and “restore” options are mutually exclusive (use «-h» to read the help text).'.N,1);
|
||||
|
||||
$lockfp=__DIR__.'/'.BNAME.'.lock';
|
||||
|
@ -224,7 +227,10 @@ do {
|
|||
$maxround=1;
|
||||
$tini=time();
|
||||
// go
|
||||
crawl([$opts['startinst']],1);
|
||||
if ($opts['restore'])
|
||||
crawl($insts,1);
|
||||
else
|
||||
crawl([$opts['startinst']],1);
|
||||
gecho('Done crawling! :-)'.N,true,false);
|
||||
$now=time();
|
||||
gecho('Crawl started on '.date('Y-m-d H:i:s',$tini).' and ended on '.date('Y-m-d H:i:s',$now).'.'.N,true,false);
|
||||
|
|
Loading…
Reference in a new issue