IRC Bot parsing

2005-07-03 Thread dave.w.turner
Hi, I started with perl not long ago. I am currently coding an IRC bot. I have all the connect code working fine, and it sits on the channel. At the moment, I am trying to make it respond to commands. I am having trouble parsing the lines recieved from the IRC server - they take the form: : P

Re: Re-starting Apache

2005-07-05 Thread dave.w.turner
Yeh, if you put a problematic line in the config files, the server won't restart until you fix it, and on windows, due to the stupid (imho) GUIs, etc. it doesn't show you the error message until you open a dos prompt, learn a foreign language, and do a double backflip whilst whistling the "star sp

Multitasking

2005-07-06 Thread dave.w.turner
Hey, I am making an IRC bot to bridge 2 channels on different networks. For this I need to scan 2 sockets for data. How do I do this? This is how I do 1 socket: while(my $input = <$sock>) { . } -- Dave All us base are belong to you. -- To unsubscribe, e-mail: [EMAIL PROTECTED]

Re: Multitasking

2005-07-09 Thread dave.w.turner
Uhhh I can't believe I just posted it non-list again. Here it is for the list: On 7/8/05, Wiggins d'Anconia <[EMAIL PROTECTED]> wrote: > Please group reply to prevent getting accidentally ignored and so > everyone can help and be helped. Also please bottom post. Whoops - sorry about that -

Re: array

2005-07-18 Thread dave.w.turner
By the way, since you mentioned chomp - what is the difference between chomp and chop? I think they are both for removing some type of un-needed whitespace - does one do space, and the other newline or something? > also chomp() the $guess variable to remove the unneeded newline. -- Dave All u

Re: Techno Boi -- was Re: Regular Expressions : Help in understanding

2005-07-18 Thread dave.w.turner
Oops - mean't to group reply On 7/18/05, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > H. Maybe techno enough to know how to download stuff his > mummy and daddy wouldn't approve of?? > > On 7/17/05, robert johnson <[EMAIL PROTECTED]> wrote: > > > > so, am i to read his email as "kisses

Re: Beep in perl

2005-07-20 Thread dave.w.turner
If on linux, and portability doesn't matter, you can get a beep wav file, and use: system "aplay beep.wav"; otherwise, I use the print "\a"; Doesn't always work in all terminals/ssh/telnet though. (but more portable that aplay anyway) BTW, ARGGHHH!!! Revenge of the single posts. On 7/20/05,

Re: Problems creating a simple variable

2005-07-21 Thread dave.w.turner
Huh? What do you want it to be? On 7/21/05, Dave Adams <[EMAIL PROTECTED]> wrote: > I want to create a variable, to be used for other stuff, using today's date. > > Can anyone help me with the second last line? > > use Time::localtime; > my $tm = localtime; > printf("The current date is > %04d%

Shuffling an file

2005-08-17 Thread dave.w.turner
Hello, I am working on a playlist managment program in perl - I need a way to shuffle the playlist - the playlist format is very simple - one filename on each line. Each file name is a reletive path, i.e: folder1/file1.mp3 folder2/file2.mp3 If possible I would like the file to be shuffled so th

Re: A sript to delete programs installed from source

2005-08-17 Thread dave.w.turner
Well, I think it's not fair to say that a package manager is a solution to the actual problem - he says: "How do i remove a program installed from source" - i.e. ALREADY installed. My only answers to this are "make uninstall" (in the origional source directory) or the program "make_uninstall". O