Sunday, February 3, 2013

resolving the error **Unexcpected Operator** in shell scripts

In Some Linux systems the full functionality of the sh or bash shell is not available.So to solve this we have to follow a few steps:

  1. open the .sh extension script file you are working with.
  2. find the clause #!/bin/sh. in most of the scripts its the very first line,
  3. just replace the #!/bin/sh with #!bin/bash.
  4. save the file and open the terminal window
  5. navigate to the directory where the file is present .
  6. now execute the command  bash ./filename.sh
and that's it , you are done with the error.

No comments:

Post a Comment