in reply to Noob question
Welcome meanroc! If this is your code you will get an error which reads:
/usr/bin/per bad interpreter: No such file or directory
To resolve this change your shebang line to:
#!/usr/bin/perl
Within perl there are more portable ways to get the current directory, for example the core module Cwd
#!/usr/bin/perl use strict; use warnings; use Cwd qw(abs_path); my $path = abs_path(); print "Path: $path\n";
|
|---|