jeudi 17 août 2017

Bash script error : syntax error near unexpected token `$pwd=`pwd`

I am running the Indic morph analyzer.However,I am getting this error when I am trying to install the script as the title says.Please help me install the script

#!/usr/bin/perl
chomp($pwd=`pwd`);
$my_path=$pwd."/amba/bin";
$my_cp_cmd="cp ".$pwd."/amba/tools/dotfiles/.vimrc .";
system("echo Compiling; cp amba/PORT/install_tlg_morph .; ./install_tlg_morph 2> ERR2 ;mkdir test");
system($cmd);
system($my_cp_cmd);
print "***Add the following line to your .bash_profile***\n";
print "PATH=\$PATH:",$my_path,"\n";

ERROR is

  auto_install.pl: line 2: syntax error near unexpected token `$pwd=`pwd`'
  auto_install.pl: line 2: `chomp($pwd=`pwd`);'

Aucun commentaire:

Enregistrer un commentaire