PDA

View Full Version : [SOLVED] /bin/bash: ./perl_script.pl: usr/bin/perl: bad interpreter: No such file or directory



NerdcoreSteve
August 20th, 2014, 07:23 PM
I wrote a perl script in ubuntu, in vim.

I put this at the top:

#!usr/bin/perl
(I also tried a -W but the result is the same)

The script works find if I run the script using perl.

When I run it with ./ I get this error:


/bin/bash: ./perl_script.pl: usr/bin/perl: bad interpreter: No such file or directory

Just to emphasize, I did not write this in windows. This script has never seen windows.

steeldriver
August 20th, 2014, 07:30 PM
Try



#!/usr/bin/perl

NerdcoreSteve
August 26th, 2014, 09:55 PM
That did it. Thanks. :)