Ignore:
Timestamp:
2004-01-22T16:19:34+13:00 (20 years ago)
Author:
jmt12
Message:

Started effecting the changes requested by Ian and David. So far I've removed the complex arguments, and have ensured that the path is correct for downloads without page requisites. I've also tried to get the workspace tree to update properly, and it is much closer than before but it is now temporarily displaying the same node twice.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gli/src/org/greenstone/gatherer/WGet.java

    r6582 r6590  
    257257    // Create the job and fill in the details from gatherer.config.
    258258    Gatherer.println("About to create a new job");
    259     // If it was decided not to download page requisites, then create the destination by basing it on the given destination, but appending the url host. If page requisites is used then WGet will do this for us
     259    // If it was decided not to download page requisites, then create the destination by basing it on the given destination, but appending the url host and paths. If page requisites is used then WGet will do this for us
    260260    if(!page_requisites) {
    261         destination = destination + url.getHost();
     261        System.err.println("Initially destination: " + destination);
     262        String almost_the_entire_path = url.getPath();
     263        int index = -1;
     264        if((index = almost_the_entire_path.lastIndexOf("/")) != -1) {
     265        almost_the_entire_path = almost_the_entire_path.substring(0, index);
     266        }
     267        destination = destination + url.getHost() + almost_the_entire_path + "/";
     268        System.err.println("Finale destination:    " + destination);
    262269    }
    263270    Job new_job = new Job(Gatherer.config.get("mirroring.debug", false), no_parents, other_hosts, page_requisites, Gatherer.config.get("mirroring.quiet", false), url, depth, destination, Gatherer.config.proxy_pass, Gatherer.config.proxy_user, this, simple);
Note: See TracChangeset for help on using the changeset viewer.