Teen Programmers Unite  
 

 

Return to forum top

Perl, that first line of it

Posted by have_dinner [send private reply] at September 03, 2001, 08:54:18 PM

Hey guys... i recently got linux RH... using the unix prompt... i create my files and everything... yet the even though i have the correct first line of my script i still have to execute the perl script with : perl script.pl

any reason for this??? help me out guys

Posted by lordaerom [send private reply] at September 03, 2001, 09:11:55 PM

your files need to be set executable.

chmod +x filename

Then you can do ./filename and have the perl interpreter invoked, assuming the first line is
#!/path/to/perl

You must be logged in to post messages and see which you have already read.

Log on
Username:
Password:
Save for later automatic logon

Register as a new user
 
Copyright TPU 2002. See the Credits and About TPU for more information.