I have a couple of errors in my script which I built in CentOS then deployed to Unix. I have the shebang #!/bin/bash on top of my scripts and execute my script using bash myscript.sh
LINE in script:
existing[0]=""
ERROR: existing[0]=: not found
LINE in script: not sure if its this -
while IFS='' read -r line || [[ -n "$line" ]]; do
or this one -
if [[ $sftp_status != 0 ]]; then
ERROR: syntax error at line 118: `i=$' unexpected
LINE in script:
i=$((i + 1))
bash -x myscript.sh.