Changeset 3 for trunk/biblehal-pop


Ignore:
Timestamp:
Apr 1, 2011, 12:01:42 PM (13 years ago)
Author:
g7moreau
Message:
  • Add dep on /etc/biblehal/biblehal.conf
  • Detele dep on LEGI laboratory name
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/biblehal-pop

    r2 r3  
    22#
    33# gabriel 2010/06/03
     4# gabriel 2011/04/01 update to biblehal
    45#
    56# apt-get install libwww-mechanize-perl libwww-perl
     
    1112use HTML::Form;
    1213
    13 my $year = shift @ARGV;
    14 
    15 die "Usage /usr/lib/biblehal/biblehal-pop year\n" if $year < 1990 or $year > 2020;
     14my $laboratory = shift @ARGV;
     15my $year       = shift @ARGV;
     16
     17die "Usage /usr/lib/biblehal/biblehal-pop laboratory year\n" if $year < 1990 or $year > 2020;
    1618
    1719mkdir '/var/cache/biblehal/download', 0750;
     
    8890
    8991# On intègre le second formulaire qui se remplit normalement via un javascript
    90 my $parser = HTML::Form->parse("$F", 'http://hal.archives-ouvertes.fr/LEGI');
     92my $parser = HTML::Form->parse("$F", "http://hal.archives-ouvertes.fr/$laboratory");
    9193    print($@) if $@;
    9294#print Dumper $parser;
     
    9496
    9597# Création du bot
    96 my $url = 'http://hal.archives-ouvertes.fr/LEGI';
     98my $url = "http://hal.archives-ouvertes.fr/$laboratory";
    9799my $bot = WWW::Mechanize->new;
    98100   $bot->proxy(['http', 'ftp'], 'http://194.254.66.70:3128');
Note: See TracChangeset for help on using the changeset viewer.