in reply to Forcing a PERL script to reload libraries

Poke through %INC, which is Perl's memory of what's already been required. It'll be obvious what you need to delete from there before calling require again.

-- Randal L. Schwartz, Perl hacker

Replies are listed 'Best First'.
Re: Re: Forcing a PERL script to reload libraries
by mr.nick (Chaplain) on Dec 20, 2000 at 20:23 UTC
    Yay!! A simple
    
    $SIG{HUP}=sub {
        delete $INC{"MyRoutines.pl"};
        require "MyRoutines.pl";
    }
    
    
    did the trick! Thank you! I didn't realize you could just modify that hash.

    Btw, I'm the same poster as the original question, I just decided to create an account :)