Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Red Wolf Chatterbox Client

by nathanvit (Beadle)
on May 09, 2003 at 14:42 UTC ( [id://256883]=perlquestion: print w/replies, xml ) Need Help??

nathanvit has asked for the wisdom of the Perl Monks concerning the following question:

Hello; i've another question for you. I'd like to use a chatterbox client. So i go to Other CB Clients to find one. At the end i decided to use RedWolf MonkChatter because it uses less modules ;-) So i cut and paste its code. I delete "+" before a lot of lines and i launch it but it give me an error:
./redwolf.pl: line 5: use: command not found ./redwolf.pl: line 6: use: command not found ./redwolf.pl: line 9: BEGIN: command not found ./redwolf.pl: line 10: syntax error near unexpected token `$win32' ./redwolf.pl: line 10: ` my($win32)=1 if($^O eq 'MSWin32');'
Have you any suggestion?
The fifth line is use Tk; but if the module is not installed it gives me another error.Am i in wrong?
Thanks.

Replies are listed 'Best First'.
Re: Red Wolf Chatterbox Client
by smitz (Chaplain) on May 09, 2003 at 14:51 UTC
    Does the first line equal
    #!path/to/perl?
    It looks like your running this through bash. If that doesn't work, try running it perl redwolf.pl

    Smitz
      My first then lines of code are:
      #!/usr/bin/perl ### Modules use Tk; use IO::Socket; ### Win32 junk BEGIN { my($win32)=1 if($^O eq 'MSWin32'); if($win32) { eval 'use Win32::Shell'; die "$@\n" if($@); } } ### Configurables $maxlines=500; $blanknode=14532; $delaysec=10; # $proxy='';
      If i launch it as ./redwolf.pl it gives me the error as in my first article. The path /usr/bin/perl is ok!!!
      On the contrary if i run perl redwolf.pl it works but it doesn't connect to my perl monks account and i can't chat with this client!!!
      Any suggestions?
Re: Red Wolf Chatterbox Client
by artist (Parson) on May 09, 2003 at 15:11 UTC
    So i cut and paste its code. I delete "+" before a lot of lines

    Well, you don't need to do that. There is always a download link for the code (d/l code) at the end of the node. Which allows you have to have the code without those '+' at the beginning.

    Also post the first few lines of code that you got (1..10), and we can see better of what you have. Mention your operating system and perl path, to have it more clear.

    artist

Re: Red Wolf Chatterbox Client
by dvergin (Monsignor) on May 10, 2003 at 06:04 UTC
    Look again at the top of the file. I just downloaded RedWolf MonkChatter and tried it. I got similar results and then noticed that '#!/usr/bin/perl' was the *second* line in the file. The first line was blank -- easy to miss.

    Once I fixed that, the program ran.

    HTH David

    ------------------------------------------------------------
    "Perl is a mess and that's good because the
    problem space is also a mess.
    " - Larry Wall

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://256883]
Approved by smitz
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others lurking in the Monastery: (7)
As of 2024-04-19 11:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found