Here is the solution:
http://www.linuxforums.org/forum/red-hat-fedora-linux/65469-bad-interpreter-no-such-file-directory.html
Quote:
#!/usr/bin/perl
die "Usage: $0 < files >\n" unless @ARGV;
for $file (@ARGV)
{
open IN, $file or die "$0: Cannot open $file for input!\n";
my @lines = <IN>;
close IN;
open OUT, "> $file" or die "$0: Cannot open $file for output!\n";
s/\r$// for @lines;
print OUT for @lines;
}
Save this file as fix_m.pl
run perl fix_m.pl yourshell.sh
No comments:
Post a Comment