#!/usr/bin/perl package Mech; BEGIN { $ENV{'DISPLAY'} = ':3.0'; unshift @INC, "/home/perl/perl-lib"; } use Modern::Perl; use EventRepository2; my $er = EventRepository2->new(display => 0, fast_mode => 1, launch => ['firefox', '-P', "Profile1", '-rep', '4244'], repl => 'localhost:4244'); $er->get ('http://slashdot.org'); $er->mySendKeys("^(l)slashdottiejksdjf"); $ENV{'DISPLAY'} = ':2.0'; my $er = EventRepository2->new(fast_mode => 1, launch => ['firefox', '-P', "Profile2", '-rep', '4242'], repl => 'localhost:4242'); $er->get ('http://nyt.com'); $er->mySendKeys("^(l)calendarie"); $ENV{'DISPLAY'} = ':1.0'; my $er = EventRepository2->new(fast_mode => 1, launch => ['firefox', '-P', "Profile3", '-rep', '4243'], repl => 'localhost:4243'); $er->get ('http://digg.com'); $er->mySendKeys("^(l)diggie");